Skip to content

Commit 94bccd4

Browse files
committed
new readthedocs instructions
1 parent e506c32 commit 94bccd4

File tree

1 file changed

+36
-5
lines changed

1 file changed

+36
-5
lines changed

Diff for: imdclient/IMDREADER.py

+36-5
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,16 @@
11
"""
22
3-
Example: Streaming an IMDv3 trajectory
4-
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
3+
Minimal Instructions for various Simulation Engine
4+
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
55
6-
To stream a trajectory from GROMACS or another simulation engine that supports
7-
IMDv3, ensure that the simulation engine is running and waiting for an IMD connection.
6+
To stream a trajectory from a simulation engine that supports IMDv3,
7+
one may use the appropriate input options to establish a connection and stream simulation data.
8+
Below, we have proided brief instructions on how to setup the various
9+
simulation engine to stream data using IMDv3.
810
9-
For example, in GROMACS, you can use ``gmx mdrun`` with the ``-imdwait`` flag
11+
GROMACS
12+
^^^^^^
13+
In GROMACS, you can use ``gmx mdrun`` with the ``-imdwait`` flag
1014
to ensure that GROMACS will wait for a client before starting the simulation.
1115
In GROMACS, you will know that the simulation is ready and waiting for the
1216
MDAnalysis IMDReader client when this line is printed to the terminal:
@@ -15,15 +19,42 @@
1519
1620
IMD: Will wait until I have a connection and IMD_GO orders.
1721
22+
LAMMPS
23+
^^^^^^
24+
25+
NAMD
26+
^^^^
27+
In NAMD, the simulation will wait for a client connection when the
28+
``IMDon`` option is set to ``yes`` in the NAMD configuration file.
29+
Other options that can be set are detailed
30+
`here <https://github.com/amruthesht/namd-3.0/blob/IMDv3-dev/IMDv3-dev.md>`_.
31+
This will produce a simulation that is ready for a client connection with the
32+
following terminal message:
33+
34+
.. code-block:: none
35+
36+
Info: INTERACTIVE MD AWAITING CONNECTION
37+
38+
39+
Example Streaming Code
40+
^^^^^^^^^^^^^^^^^^^^^^^
41+
1842
Once the simulation is ready for a client connection, setup your :class:`Universe`
1943
like this: ::
2044
2145
import imdclient
2246
import MDAnalysis as mda
2347
# Pass host and port of the listening GROMACACS simulation
2448
# server as the trajectory argument
49+
50+
# GROMACS
2551
u = mda.Universe("topology.tpr", "localhost:8888")
2652
53+
# LAMMPS
54+
55+
# NAMD
56+
u = mda.Universe("topology.psf", "localhost:8888")
57+
2758
Classes
2859
^^^^^^^
2960

0 commit comments

Comments
 (0)