Skip to content

Commit

Permalink
Fix to_hoomd for convex polygons
Browse files Browse the repository at this point in the history
  • Loading branch information
janbridley committed Oct 30, 2024
1 parent d612efe commit 2912f08
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions coxeter/shapes/polygon.py
Original file line number Diff line number Diff line change
Expand Up @@ -800,6 +800,7 @@ def to_hoomd(self):
self.centroid = np.array([0, 0, 0])
data = self.to_json(["vertices", "centroid", "area", "inertia_tensor"])
hoomd_dict = _map_dict_keys(data, key_mapping=_hoomd_dict_mapping)
hoomd_dict |= {"vertices": self.vertices[:, :2]}
hoomd_dict["sweep_radius"] = 0.0

self.centroid = old_centroid
Expand Down

0 comments on commit 2912f08

Please sign in to comment.