Hi Peter,
thanks a lot for the very helpful explanation.
There seems to be an upper bound on how many simulation object openMM can allocate for the OpenCL platform. Once I try to create more than 19 simulation objects the python interpreter exists with the following error message
Code: Select all
Traceback (most recent call last):
File "remd_multiprocess.py", line 79, in <module>
simulation=Simulation(pdb.topology, system, integrator, platform, properties)
File "/home/trendelkamp/.local/lib/python2.7/site-packages/simtk/openmm/app/simulation.py", line 79, in __init__
self.context = mm.Context(system, integrator, platform, platformProperties)
File "/home/trendelkamp/.local/lib/python2.7/site-packages/simtk/openmm/openmm.py", line 4594, in __init__
this = _openmm.new_Context(*args)
Exception: Error compiling kernel:
The behaviour for the CUDA platform is different. I can assign only one Simulation object to a device. If I try to assign more than one simulation to a single device I get the following error message.
Code: Select all
Traceback (most recent call last):
File "remd_multiprocess.py", line 79, in <module>
simulation=Simulation(pdb.topology, system, integrator, platform, properties)
File "/home/trendelkamp/.local/lib/python2.7/site-packages/simtk/openmm/app/simulation.py", line 79, in __init__
self.context = mm.Context(system, integrator, platform, platformProperties)
File "/home/trendelkamp/.local/lib/python2.7/site-packages/simtk/openmm/openmm.py", line 4594, in __init__
this = _openmm.new_Context(*args)
Exception: Error setting device flags cannot set while device is active in this process
I want to perform replica exchange MD on N_DEVICE GPUs. Each device integrating at a single temperature. Most likely there will be more temperatures than available devices, so that I have to split up the work into blocks of N_DEVICE simulations, with parallel execution within blocks.
This is why I wanted to assign more than one simulation to a single device, but maybe this is not the preferred strategy.
Thanks,
Ben