compute_Pbest - compute gbest weird behavior
K1one44 opened this issue · 0 comments
K1one44 commented
Hello,
thanks for that job.
i encounter an issue in usage:
I prepare my own optimization loops and an issu eoccurs in gbest computing the output value is not the minimum value.
i modify and try directly using GlobalBestPSO or GeneralOptimizerPSO and both return me that error at the end of first iterations run :
"mask_cost = swarm.current_cost < swarm.pbest_cost
TypeError: '>' not supported between instances of 'float' and 'NoneType' "
resulting code stop i guess it look like at first run the swarm.pbest_cost not been initialize
i am on
Win 10
Python 3.9.6
Pywswarms 1.3.0