Dynamic group from filter.type

13 views
Skip to first unread message

S.L. Lee

unread,
Sep 5, 2021, 11:04:40 PMSep 5
to hoomd-users
Dear all,
I try to add new particles during the simulation, but I am confused with the group bulit through the hoomd.filter.

As described in the documentation of HOOMD-blue 3.0.0-beta.8, hoomd.filter part, "To maintain high performance, filters are not re-evaluated on every use ... even if the state of the system has changed." But the next paragraph is "Groups are not completely static. HOOMD-blue re-evaluates the filter specifications and updates the group membership whenever the number of particles in the simulation changes."

Does this mean that the group is static now but will be dynamic in the future release? If yes, is there any way to realize the dynamic group in the current release? Thanks in advance.

Best regards,
Lee

Joshua Anderson

unread,
Sep 7, 2021, 3:41:34 PMSep 7
to hoomd...@googlegroups.com
Lee,

The next beta release includes the FilterUpdater which allows you to schedule re-evaluations of the filters on specific time steps: https://hoomd-blue.readthedocs.io/en/latest/module-hoomd-update.html#hoomd.update.FilterUpdater

Filters are always re-evaluated when particles are added to the simulation.
------
Joshua A. Anderson, Ph.D.
Research Area Specialist, Chemical Engineering, University of Michigan
> --
> You received this message because you are subscribed to the Google Groups "hoomd-users" group.
> To unsubscribe from this group and stop receiving emails from it, send an email to hoomd-users...@googlegroups.com.
> To view this discussion on the web visit https://groups.google.com/d/msgid/hoomd-users/a4c5d4dd-8d76-4972-9e73-00e22866de4fn%40googlegroups.com.

S.L. Lee

unread,
Sep 8, 2021, 1:34:02 AMSep 8
to hoomd-users
Thanks a lot!
I solved my issue, which resulted from the changing particle index, and i used the tag instead.
By the way, i used the "get_snapshot" and "set_snapshot" to add new particles, and they are so expensive!!!!

Best,
Lee

Joshua Anderson

unread,
Sep 8, 2021, 5:13:39 AMSep 8
to hoomd...@googlegroups.com
Lee,

Yes, get_snapshot and set_snapshot are very expensive. Especially in MPI or when using the GPU.

If you have suggestions for API to add particles, feel free to post a feature request issue on GitHub. There is C++ code to do this from v2, but we have not yet designed or implemented the Python API for v3.
------
Joshua A. Anderson, Ph.D.
Research Area Specialist, Chemical Engineering, University of Michigan

> To view this discussion on the web visit https://groups.google.com/d/msgid/hoomd-users/7b08e6a8-a3c3-427f-8940-9fbe0391c36cn%40googlegroups.com.

Reply all
Reply to author
Forward
0 new messages