File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -49,9 +49,9 @@ def RunScript(self,
4949 # we make a deepcopy of the input clouds
5050 df_clouds = [df_cvt_bindings .cvt_rhcloud_2_dfcloud (cloud .Duplicate ()) for cloud in i_clouds ]
5151 df_merged_cloud = dfb_geometry .DFPointCloud ()
52- df_merged_cloud .remove_statistical_outliers (100 , 1.5 )
5352 for pc in df_clouds :
5453 df_merged_cloud .add_points (pc )
54+ df_merged_cloud .remove_statistical_outliers (100 , 1.5 )
5555
5656 df_beams = i_assembly .beams
5757
Original file line number Diff line number Diff line change @@ -28,8 +28,9 @@ def RunScript(self,
2828 i_allow_curved_joint_faces = False
2929
3030 for brep in i_breps :
31- brep .Faces .ShrinkFaces ()
32- beam = DFBeam .from_brep_face (brep , i_is_roundwood , i_allow_curved_joint_faces )
31+ brep_copy = brep .DuplicateBrep ()
32+ brep_copy .Faces .ShrinkFaces ()
33+ beam = DFBeam .from_brep_face (brep_copy , i_is_roundwood , i_allow_curved_joint_faces )
3334 beams .append (beam )
3435
3536 o_assembly = DFAssembly (beams , i_assembly_name )
Original file line number Diff line number Diff line change @@ -108,7 +108,9 @@ def __post_init__(self):
108108 self .n_step = max (lengths ) if lengths else 0
109109
110110 def add_step (self , new_poses : list [DFPose ]):
111- for i , pose in enumerate (new_poses ):
111+ element_count = max (len (new_poses ), len (self .poses_per_element_dictionary ))
112+ for i in range (element_count ):
113+ pose = new_poses [i ] if i < len (new_poses ) else None
112114 if f"element_{ i } " not in self .poses_per_element_dictionary :
113115 self .poses_per_element_dictionary [f"element_{ i } " ] = DFPosesBeam ({}, 4 )
114116 for j in range (self .n_step ):
You can’t perform that action at this time.
0 commit comments