This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| #!/usr/bin/python | |
| #-*- coding: latin-1 -*- | |
| """This module contains pure Python implementations of the | |
| Levenberg-Marquardt algorithm for data fitting. | |
| """ | |
| import numpy | |
| from numpy import inner, max, diag, eye, Inf, dot | |
| from numpy.linalg import norm, solve |