i have image pick randow row in , try fit gaussian curve in row. using scipy.optimize curve_fit method fitting gaussian. picking of randow rows according array vector [10, 20, 40, 60, 100], meaning in first try pick 10 randow rows (hence, 10 gaussian fits) in image, then, more rows selected , on. most of time, code working, however, error (especially, when number of rows large: around 60 or more), says optimal parameters not found . i have found similar posts in stackoverflow still can not able solve problem. seems problem appears quite curve_fit method . laser beam, chance? ;-) anyway, problem rows selected "hard" fit gaussian curve scipy's curve_fit function. first suggestion debug (using e.g. python's logging module) see if error pops on specific rows. my second suggestion change initial guess curve_fit. rows curve-fitting possible, should able extract few parameters. on other rows, mean of gaussian @ approximately same position , aplitud...
Comments
Post a Comment