MCPcopy Create free account
hub / github.com/lazyprogrammer/machine_learning_examples / f

Function f

rl3v2/visualize_es.py:5–7  ·  view source on GitHub ↗
(x, y)

Source from the content-addressed store, hash-verified

3
4# Objective function to minimize (you can change this)
5def f(x, y):
6 # return np.sin(x) + np.cos(y)
7 return -((x - 1)**2 + y**2)
8
9# Evolution Strategies optimizer (simple version)
10def evolution_strategies(

Callers 4

evolution_strategiesFunction · 0.70
visualize_esFunction · 0.70
evolution_strategyFunction · 0.50
evolution_strategyFunction · 0.50

Calls

no outgoing calls

Tested by

no test coverage detected