pyswarms icon indicating copy to clipboard operation
pyswarms copied to clipboard

Optimizing using pre-defined options of positive integers

Open soso-maitha opened this issue 2 years ago • 0 comments

Hello, Thanks for this great library. I want to minimize an objective function that takes two parameters k and a. But the parameters values have to be from these predifned options which are k=[3,4,5,6,7,8,9,10], a=[500,1000,2000,3000,4000,5000,6000,7000]

The reason I am using PSO because some long operation needs to be done in between.

But PSO works with random floats. Is there any current option to round the paricles float values (after being initialize and recalcuated in each iteration) to positive integers that are in my predifned list of options. Or is there anyway I can put this restriction ?

Thanks and regards,

soso-maitha avatar Jul 28 '22 12:07 soso-maitha