# Load cluster in my Python code

**URL:** <https://discourse.mcneel.com/t/load-cluster-in-my-python-code/113237>\
**Category:** Scripting\
**Tags:** ghpython\
**Created:** [November 26, 2020, 3:30pm UTC](https://discourse.mcneel.com/t/load-cluster-in-my-python-code/113237 "2020-11-26T15:30:25Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![architect.civil5](https://sea3.discourse-cdn.com/mcneel/user_avatar/discourse.mcneel.com/architect.civil5/32/500786_2.png) [@architect.civil5](https://discourse.mcneel.com/u/architect.civil5)\
**Post date:** [November 26, 2020, 3:30pm UTC](https://discourse.mcneel.com/t/load-cluster-in-my-python-code/113237/1 "2020-11-26T15:30:25Z")

</div>

Hello i created a cluster with C # if I want to load this cluster in my Python code? Is it possible?  
I wrote such a line, but it got an error and the cluster was not found at all(_for example this "extrudemesh "components_ )

```python
import Grasshopper.Folders as fo
    fo.ClusterFolders.Add.#my_cluster(extrudeMeshc#)

```

![photo_2020-11-23_12-12-50](https://global.discourse-cdn.com/mcneel/uploads/default/original/4X/d/0/4/d04334b54d6f62b0b7adc344cca100db6ea7490b.jpeg)

---

<div class="post-metadata">

**Author:** ![Mahdiyar](https://sea3.discourse-cdn.com/mcneel/user_avatar/discourse.mcneel.com/mahdiyar/32/472862_2.png) [@Mahdiyar](https://discourse.mcneel.com/u/Mahdiyar)\
**Post date:** [November 26, 2020, 3:46pm UTC](https://discourse.mcneel.com/t/load-cluster-in-my-python-code/113237/2 "2020-11-26T15:46:21Z")

</div>

> [@Component that loads a cluster in ghpython](https://discourse.mcneel.com/t/component-that-loads-a-cluster-in-ghpython/107804/2):
>
> #python import Grasshopper as gh cluster = gh.Kernel.Special.GH\_Cluster() cluster.CreateFromFilePath(path) cluster.Params.Input[0].AddVolatileData(gh.Kernel.Data.GH\_Path(0), 0, input) doc = gh.Kernel.GH\_Document() doc.Enabled = True doc.AddObject(cluster, True, 0) structure = cluster.Params.Output[0].VolatileData tree = gh.DataTree[object]() tree.MergeStructure(structure, gh.Kernel.Parameters.Hints.GH\_NullHint()) a = tree doc.Enabled = False doc.RemoveObject(cluster, False) doc.D…
