- SteadyState.find(particles=20, iterations=20, processes=None)
Find parameters that result in a steady state concentration close to the target image
Uses particle swarm to minimize the difference between the rescaled concentration and the target image, as well as the distance from a steady state solution.
particles (int) – The number of particles in the particle swarm
iterations (int) – The number of particle swarm iterations
processes – The number of processes to use (the default
Nonemeans use all available cpu cores)
the best parameters found
- Return type
List of float
On Windows, calling this function from a jupyter notebook can result in an error message of the form Can’t get attribute ‘apply_params’ on <module ‘__main__’, where
apply_paramsis the function you have defined to apply the parameters to the model. This is a known issue with Python multiprocessing, and a workaround is to define the
apply_paramsfunction in a separate .py file and import it into the notebook.