File tree Expand file tree Collapse file tree 4 files changed +17
-18
lines changed
Expand file tree Collapse file tree 4 files changed +17
-18
lines changed Original file line number Diff line number Diff line change @@ -30,7 +30,6 @@ def RunScript(self,
3030 if i_association_threshold is None :
3131 i_association_threshold = 0.1
3232
33- o_aggregated_clusters = []
3433 o_face_clusters = []
3534 df_clusters = []
3635 # we make a deepcopy of the input clouds
@@ -74,13 +73,13 @@ def RunScript(self,
7473
7574 df_clusters .append (df_asssociated_cluster )
7675
77- o_aggregated_clusters = [df_cvt_bindings .cvt_dfcloud_2_rhcloud (cluster ) for cluster in df_clusters ]
76+ o_beam_clouds = [df_cvt_bindings .cvt_dfcloud_2_rhcloud (cluster ) for cluster in df_clusters ]
7877
79- for o_aggregated_cluster in o_aggregated_clusters :
80- if not o_aggregated_cluster .IsValid :
81- o_aggregated_cluster = None
78+ for o_beam_cloud in o_beam_clouds :
79+ if not o_beam_cloud .IsValid :
80+ o_beam_cloud = None
8281 ghenv .Component .AddRuntimeMessage (RML .Warning , "Some beams could not be segmented and were replaced by 'None'" ) # noqa: F821
8382
84- o_face_clusters = th .list_to_tree (o_face_clusters )
83+ o_face_clouds = th .list_to_tree (o_face_clusters )
8584
86- return o_aggregated_clusters , o_face_clusters
85+ return [ o_beam_clouds , o_face_clouds ]
Original file line number Diff line number Diff line change 6464 ],
6565 "outputParameters" : [
6666 {
67- "name" : " o_clusters " ,
68- "nickname" : " o_clusters " ,
69- "description" : " The clouds associated to each beam." ,
67+ "name" : " o_beam_clouds " ,
68+ "nickname" : " o_beam_clouds " ,
69+ "description" : " The merged clouds associated to each beam." ,
7070 "optional" : false ,
7171 "sourceCount" : 0 ,
7272 "graft" : false
7373 },
7474 {
75- "name" : " o_face_clusters " ,
76- "nickname" : " o_face_clusters " ,
77- "description" : " The clouds associated to each face." ,
75+ "name" : " o_face_clouds " ,
76+ "nickname" : " o_face_clouds " ,
77+ "description" : " The datatree of clouds associated to each face." ,
7878 "optional" : false ,
7979 "sourceCount" : 0 ,
8080 "graft" : false
Original file line number Diff line number Diff line change 1515
1616class DFPoseEstimation (component ):
1717 def RunScript (self ,
18- i_face_clusters : Grasshopper .DataTree [Rhino .Geometry .PointCloud ],
18+ i_face_clouds : Grasshopper .DataTree [Rhino .Geometry .PointCloud ],
1919 i_assembly ,
2020 i_reset : bool ,
2121 i_save : bool ):
2222
23- clusters_per_beam = th .tree_to_list (i_face_clusters )
23+ clusters_per_beam = th .tree_to_list (i_face_clouds )
2424 # ensure assembly has enough beams
2525 if len (i_assembly .beams ) < len (clusters_per_beam ):
2626 ghenv .Component .AddRuntimeMessage (RML .Warning , "Assembly has fewer beams than input clouds" ) # noqa: F821
Original file line number Diff line number Diff line change 1414 "iconDisplay" : 2 ,
1515 "inputParameters" : [
1616 {
17- "name" : " i_face_clusters " ,
18- "nickname" : " i_face_clusters " ,
19- "description" : " clouds whose pose is to be calculated" ,
17+ "name" : " i_face_clouds " ,
18+ "nickname" : " i_face_clouds " ,
19+ "description" : " datatree of beam clouds whose pose is to be calculated" ,
2020 "optional" : false ,
2121 "allowTreeAccess" : true ,
2222 "showTypeHints" : true ,
You can’t perform that action at this time.
0 commit comments