Black box optimization in Python

asked 2017-08-12 02:01:37 -0600

Amir90 gravatar image

Hello, I am running a black box optimization routine with pybrain package.I want to use genetic algorithm (GA) and I have four parameters (x,y,z and w). can you help me how can I define these parameters? I have an equal constrain (x+y+z+w=1) and bounds (0<x,y,z,w&lt;1). how="" can="" i="" define="" them?="" my="" overall="" code="" is="" as="" follows:<="" p="">

def objF():
.....
return output

x0 = np.array([20,20,20,20]) %initial values
l = GA(objF, x0)
l.minimize = True
l.learn()
edit retag flag offensive close merge delete