spotpy: Bug: sceua gets stuck with MPI after burn-in
Hey there,
from spotpy 1.5.0 on, sce optimization with MPI get stuck after the burn in phase. Here is a minimal example:
from spotpy.algorithms import sceua
from spotpy.examples.spot_setup_rosenbrock import spot_setup
setup = spot_setup("sceua") # spot_setup() for spotpy 1.4.6
sampler = sceua(setup, parallel="mpi", dbname='db', dbformat="csv")
sampler.sample(repetitions=10000, ngs=4)
Running with
mpiexec -n 4 python3 test.py
Gives the following output:
Initializing the Shuffled Complex Evolution (SCE-UA) algorithm with 10000 repetitions
The objective function will be minimized
Initializing the Shuffled Complex Evolution (SCE-UA) algorithm with 10000 repetitions
The objective function will be minimized
Initializing the Shuffled Complex Evolution (SCE-UA) algorithm with 10000 repetitions
The objective function will be minimized
Initializing the Shuffled Complex Evolution (SCE-UA) algorithm with 10000 repetitions
The objective function will be minimized
Starting burn-in sampling...
Initialize database...
['csv', 'hdf5', 'ram', 'sql', 'custom', 'noData']
* Database file 'db.csv' created.
Burn-in sampling completed...
Starting Complex Evolution...
ComplexEvo loop #1 in progress...
And from there on, nothing more happens. With parallel="seq"
it takes about 5 seconds to finish.
Do you know what the problem could be?
I’ve got mpi4py 3.0.2
installed and I am using Python 3.6.8. With spotpy 1.4.6 everything is working. From 1.5.0 on the above mentioned behavior occurs.
Cheers, Sebastian
About this issue
- Original URL
- State: closed
- Created 5 years ago
- Comments: 15 (11 by maintainers)
Commits related to this issue
- Fix for #226 — committed to thouska/spotpy by thouska 5 years ago
- Update version number #226 — committed to thouska/spotpy by thouska 5 years ago
- Exclude unittests from build and rename them to tests #226 — committed to thouska/spotpy by thouska 5 years ago
- Merge pull request #232 from thouska/Move-tests-on-toplevel Moves tests on toplevel, partly removes jit from hymod_python.py #226 — committed to thouska/spotpy by thouska 5 years ago
Many thanks @MuellerSeb that you directly tested everything and reported such a detailed way how to fix the new problems. As you recommended, I removed the unittest import, renamed the unittests folder to tests and moved the whole thing to the toplevel. I like the new structure and think this makes totaly sense. As @hpsone found out faster than I could answer to this issue: There is a new version on pypi containing the fix.