ur-whitelab / hoomd-tf

A plugin that allows the use of Tensorflow in Hoomd-Blue for GPU-accelerated ML+MD
https://hoomd-tf.readthedocs.io
MIT License
30 stars 8 forks source link

box_size fails with 3D box read from .gsd file #259

Closed RainierBarrett closed 3 years ago

RainierBarrett commented 3 years ago

Hi all! I'm working with reading from a .gsd trajectory in order to do CG mapping. I followed along with the example notebooks, but I get an issue when I try to apply the mapping and output the mapped particle positions. Attached is a MWE with two requisite .gsd files and a jupyter notebook. In the final cell of the notebook, if youcan manually feed in the correct [16., 16., 16.] for box_size, but in the examples I was following, it is fed in as htf.box_size(box). However, if we print that out we can see that the third box dimension is coming out as zero, which causes nans to show up for the mapped particle positions.

box-size-mwe.zip

whitead commented 3 years ago

Hi @RainierBarrett thanks for pointing this out! I believe this line needs to be corrected to match the box doc. @hgandhi2411 or @geemi725 can one of you set-up a PR for this?

hgandhi2411 commented 3 years ago

Addressed by #260