Hello,
I'm trying to use skimpy for parallel processing (via Python's multiprocessing module) to speed up simulations. However, I am encountering a PicklingError related to the Convenience class when I attempt to parallelize my simulations.
The error I get is:
_pickle.PicklingError: Can't pickle <skimpy.mechanisms.convenience.make_convenience..Convenience object>
It seems that because the Convenience class is dynamically generated within the make_convenience function, Python's multiprocessing module is unable to serialize it for passing between processes. This prevents me from utilizing multiprocessing to parallelize my computations.
I understand that the dynamic class generation provides flexibility for different reaction mechanisms, but it causes issues with multiprocessing due to the pickling requirement.
Do you have any suggestions or workarounds for how to use skimpy in a parallel processing context?
Hello,
I'm trying to use skimpy for parallel processing (via Python's multiprocessing module) to speed up simulations. However, I am encountering a PicklingError related to the Convenience class when I attempt to parallelize my simulations.
The error I get is:
_pickle.PicklingError: Can't pickle <skimpy.mechanisms.convenience.make_convenience..Convenience object>
It seems that because the Convenience class is dynamically generated within the make_convenience function, Python's multiprocessing module is unable to serialize it for passing between processes. This prevents me from utilizing multiprocessing to parallelize my computations.
I understand that the dynamic class generation provides flexibility for different reaction mechanisms, but it causes issues with multiprocessing due to the pickling requirement.
Do you have any suggestions or workarounds for how to use skimpy in a parallel processing context?