You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We need to make sure ingredients don't overlap with surfaces defined by a mesh
Solution
This is some code we removed that may be a good check to do but is currently redundant with other surface checks
# the compartment the ingr belongs to# current_ingr_compartment = self.get_compartment(self.env)# for compartment in self.env.compartments:# if current_ingr_compartment.name == compartment.name:# continue# distances, ingr_indexes = compartment.OGsrfPtsBht.query(packing_location)# # NOTE: this could be optimized by walking down the sphere tree representation# # of the instead of going right to the bottom# if distances < self.encapsulating_radius + compartment.encapsulating_radius:# # pos_of_attempting_ingr = self.get_new_pos(# # self, packing_location, rotation, self.positions[total_levels - 1]# # )# distances, ingr_indexes = compartment.OGsrfPtsBht.query(# [packing_location]# )# radii = [self.radius]# overlap_distance = distances - numpy.array(radii)# overlap_indexes = numpy.nonzero(overlap_distance < 0.0)[0]# if len(overlap_indexes) != 0:# return True
Alternatives
Please describe any alternatives you've considered, even if you've dismissed them
The text was updated successfully, but these errors were encountered:
Use Case
We need to make sure ingredients don't overlap with surfaces defined by a mesh
Solution
This is some code we removed that may be a good check to do but is currently redundant with other surface checks
Alternatives
Please describe any alternatives you've considered, even if you've dismissed them
The text was updated successfully, but these errors were encountered: