Skip to content
Snippets Groups Projects
Commit 933ff9f9 authored by Wuttke, Joachim's avatar Wuttke, Joachim
Browse files

normalize Py math code

parent 7c93ef8b
No related branches found
No related tags found
2 merge requests!1847rebase on latest r21,!1839Improve messages from Py.Fit tests, and disable Rosenbrock test case while waiting for #693.
......@@ -13,14 +13,9 @@ class Rosenbrock:
self.m_expected_params = [1, 1.0]
def objective_function(self, params):
"""
Returns the value of Rosenbrock function
"""
x = params["x"].value
y = params["y"].value
tmp1 = y - x * x
tmp2 = 1 - x
return 100 * tmp1 * tmp1 + tmp2 * tmp2
return (1 - x)**2 + 100 * (y - x**2)**2
def decaying_sin(params, x):
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment