-
Notifications
You must be signed in to change notification settings - Fork 296
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
75fe7d5
commit a77124d
Showing
4 changed files
with
51 additions
and
11 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,24 @@ | ||
# simple test to check setMPIComm and mpi4py | ||
import plumed | ||
import os | ||
import unittest | ||
try: | ||
from mpi4py import MPI | ||
HAS_MPI4PY=True | ||
except ImportError: | ||
HAS_MPI4PY=False | ||
|
||
class Test(unittest.TestCase): | ||
if HAS_MPI4PY: | ||
def test(self): | ||
|
||
comm = MPI.COMM_WORLD | ||
p = plumed.Plumed() | ||
p.cmd("setNatoms",2) | ||
p.cmd("setLogFile","test.log") | ||
p.cmd("setMPIComm",comm) | ||
p.cmd("init") | ||
|
||
|
||
if __name__ == "__main__": | ||
unittest.main() |