if not isinstance(lb, list):
lb = [lb] * dim
if not isinstance(ub, list):
ub = [ub] * dim
bestIndividual=numpy.zeros(dim)
scores=numpy.random.uniform(0.0, 1.0, popSize)
bestScore=float("inf")
ga = numpy.zeros((popSize, dim))
for i in range(dim):
ga[:, i]=numpy.random.uniform(0,1,popSize) * (ub[i] - lb[i]) + lb[i]
convergence_curve=numpy.zeros(iters)
print("GA is optimizing \""+objf.__name__+"\"")