gmso
gmso copied to clipboard
Implement rigid bodies for GSD writer.
After switching GMSO to the backend writer in mBuild for HOOMD snapshots and GSD files, I did some poking around about how to hand off the rigid ID when converting from mbuild to GMSO. It looks like the snapshot writers don't yet support rigid body IDs, and even if they did, it looks like we're missing a way to pass in rigid body IDs in convert_mbuild.py
convert_hoomd.py
accepts a rigid_bodies
argument when writing out a Hoomd snapshot, but there is no way to get this info from the topology object. Since in most workflows, the rigid body IDs are created and stored in the mBuild Compound class, I think this information should be passed along to GMSO when applicable.
We would need to 1) create a rigid_ids
attribute in gmso.core.Topology
which would be a list of ints, and 2) populate this attribute when parsing the Compound in from_mbuild
.