imdclient 0.1.4__py3-none-any.whl → 0.2.0b0__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- imdclient/IMDClient.py +24 -22
- imdclient/__init__.py +0 -5
- imdclient/data/namd/md/namd3 +0 -0
- imdclient/data/namd/md/namd_v3_nst_1.namd +1 -1
- imdclient/tests/base.py +82 -103
- imdclient/tests/datafiles.py +1 -1
- imdclient/tests/docker_testing/docker.md +1 -1
- imdclient/tests/hpc_testing/lammps/README.md +2 -2
- imdclient/tests/hpc_testing/namd/README.md +93 -19
- imdclient/tests/minimalreader.py +86 -0
- imdclient/tests/server.py +4 -3
- imdclient/tests/test_gromacs.py +15 -3
- imdclient/tests/test_imdclient.py +8 -7
- imdclient/tests/test_lammps.py +22 -19
- imdclient/tests/test_manual.py +24 -22
- imdclient/tests/test_namd.py +39 -16
- imdclient/tests/test_utils.py +31 -0
- imdclient/utils.py +50 -17
- {imdclient-0.1.4.dist-info → imdclient-0.2.0b0.dist-info}/METADATA +60 -39
- {imdclient-0.1.4.dist-info → imdclient-0.2.0b0.dist-info}/RECORD +24 -28
- {imdclient-0.1.4.dist-info → imdclient-0.2.0b0.dist-info}/WHEEL +1 -1
- {imdclient-0.1.4.dist-info → imdclient-0.2.0b0.dist-info/licenses}/AUTHORS.md +4 -1
- {imdclient-0.1.4.dist-info → imdclient-0.2.0b0.dist-info/licenses}/LICENSE +3 -1
- imdclient/IMD.py +0 -132
- imdclient/backends.py +0 -352
- imdclient/results.py +0 -332
- imdclient/streamanalysis.py +0 -1056
- imdclient/streambase.py +0 -199
- imdclient/tests/test_imdreader.py +0 -717
- imdclient/tests/test_stream_analysis.py +0 -61
- {imdclient-0.1.4.dist-info → imdclient-0.2.0b0.dist-info}/top_level.txt +0 -0
@@ -1,61 +0,0 @@
|
|
1
|
-
import imdclient
|
2
|
-
from MDAnalysisTests.datafiles import (
|
3
|
-
COORDINATES_TOPOLOGY,
|
4
|
-
COORDINATES_H5MD,
|
5
|
-
)
|
6
|
-
import MDAnalysis as mda
|
7
|
-
from .utils import (
|
8
|
-
get_free_port,
|
9
|
-
create_default_imdsinfo_v3,
|
10
|
-
)
|
11
|
-
from .server import InThreadIMDServer
|
12
|
-
from MDAnalysis.analysis.rms import RMSF
|
13
|
-
from numpy.testing import (
|
14
|
-
assert_almost_equal,
|
15
|
-
)
|
16
|
-
import numpy as np
|
17
|
-
import pytest
|
18
|
-
from imdclient.IMD import IMDReader
|
19
|
-
|
20
|
-
|
21
|
-
class TestStreamAnalysis:
|
22
|
-
|
23
|
-
@pytest.fixture
|
24
|
-
def port(self):
|
25
|
-
return get_free_port()
|
26
|
-
|
27
|
-
@pytest.fixture
|
28
|
-
def universe(self):
|
29
|
-
return mda.Universe(COORDINATES_TOPOLOGY, COORDINATES_H5MD)
|
30
|
-
|
31
|
-
@pytest.fixture
|
32
|
-
def imdsinfo(self):
|
33
|
-
return create_default_imdsinfo_v3()
|
34
|
-
|
35
|
-
@pytest.fixture
|
36
|
-
def imd_universe(self, universe, imdsinfo, port):
|
37
|
-
server = InThreadIMDServer(universe.trajectory)
|
38
|
-
server.set_imdsessioninfo(imdsinfo)
|
39
|
-
server.handshake_sequence("localhost", port, first_frame=True)
|
40
|
-
|
41
|
-
imd_universe = mda.Universe(COORDINATES_TOPOLOGY, f"imd://localhost:{port}")
|
42
|
-
server.send_frames(1, 5)
|
43
|
-
|
44
|
-
yield imd_universe
|
45
|
-
server.cleanup()
|
46
|
-
|
47
|
-
def test_rmsf(self, imd_universe, universe):
|
48
|
-
imd_rmsf = RMSF(imd_universe.atoms).run()
|
49
|
-
rmsf = RMSF(universe.atoms).run()
|
50
|
-
|
51
|
-
assert_almost_equal(imd_rmsf.results.rmsf, rmsf.results.rmsf)
|
52
|
-
|
53
|
-
def test_stack_rmsf(self, imd_universe, universe):
|
54
|
-
r1 = RMSF(imd_universe.atoms)
|
55
|
-
r2 = RMSF(imd_universe.atoms)
|
56
|
-
imdclient.StackableAnalysis(imd_universe.trajectory, [r1, r2]).run()
|
57
|
-
|
58
|
-
rmsf = RMSF(universe.atoms).run()
|
59
|
-
|
60
|
-
assert_almost_equal(r1.results.rmsf, rmsf.results.rmsf)
|
61
|
-
assert_almost_equal(r2.results.rmsf, rmsf.results.rmsf)
|
File without changes
|