Jul-10-2019, 07:23 PM
I don't know if this is the correct forum but,
I am doing some Python Embedding from:
https://docs.python.org/3.6/extending/em...-embedding
I cannot figure out how to pass the keyword rosen from the C/Python API in the nelderMead function argument correctly.
I have tried hard-coding PyUnicode_DecodeFSDefault but it outputs a string into the Python when rosen itself is a type class
from scipy.
please advise
.
I am doing some Python Embedding from:
https://docs.python.org/3.6/extending/em...-embedding
I cannot figure out how to pass the keyword rosen from the C/Python API in the nelderMead function argument correctly.
I have tried hard-coding PyUnicode_DecodeFSDefault but it outputs a string into the Python when rosen itself is a type class
from scipy.
from scipy.optimize import minimize, rosen, rosen_der def nelderMead(func): x0 = [1.3, 0.7, 0.8, 1.9, 1.2] res = minimize(func, x0, method='Nelder-Mead', tol=1e-6) print(res.x)
please advise
