code: def test_to_dict():
      tree = rrcf.RCTree()
      tree.insert_point([0.0, 0.0], index=0)
      tree.insert_point([0.0, 0.0], index=1)
      tree.insert_point([0.0, 0.0], index=2)
      tree.insert_point([0.0, 1.0], index=3)
      obj = tree.to_dict()
      X = np.random.randn(10, 3)
      X[5] = X[2]
      tree = rrcf.RCTree(X)
      obj = tree.to_dict()
      with open("tree.json", "w") as outfile:
          json.dump(obj, outfile)
  
file_path: rrcf/test/test_rrcf.py
imports: import json
  import numpy
  import rrcf
label_desc: Use image node_id 14 for calling a global function with example usage: test_to_dict() without return types