I see you are writing Python code for gradient descent optimization. A general problem for gradient descent, particularly for more complex equations, is the choice of initial parameters to start the "descent" in error space. Without good starting parameters, the algorithm will stop in a local error minimum. For this reason the authors of scipy have added a genetic algorithm for initial parameter estimation for use in non-linear optimization. The module is named scipy.optimize.differential_evolution, and it uses the Latin Hypercube algorithm for a thorough search of parameter space.
I have used scipy's Differential Evolution genetic algorithm to determine initial parameters for fitting a double Lorentzian peak equation to Raman spectroscopy of carbon nanotubes and found that the results were excellent. The GitHub project, with a test spectroscopy data file, is:
If you have any questions, please let me know. My background is in nuclear engineering and industrial radiation physics, and I love Python, so I will be glad to help.
I see you are writing Python code for gradient descent optimization. A general problem for gradient descent, particularly for more complex equations, is the choice of initial parameters to start the "descent" in error space. Without good starting parameters, the algorithm will stop in a local error minimum. For this reason the authors of scipy have added a genetic algorithm for initial parameter estimation for use in non-linear optimization. The module is named scipy.optimize.differential_evolution, and it uses the Latin Hypercube algorithm for a thorough search of parameter space.
I have used scipy's Differential Evolution genetic algorithm to determine initial parameters for fitting a double Lorentzian peak equation to Raman spectroscopy of carbon nanotubes and found that the results were excellent. The GitHub project, with a test spectroscopy data file, is:
https://github.com/zunzun/RamanSpectroscopyFit
If you have any questions, please let me know. My background is in nuclear engineering and industrial radiation physics, and I love Python, so I will be glad to help.
James Phillips