Commit dc41e46e authored by Monica Rainer's avatar Monica Rainer
Browse files

Small changes in warning messages

parent 1aa397b8
......@@ -547,7 +547,10 @@ def UNe_calibrate(lamp,order,select_lines,all_lines,use_oliva=CONFIG['CAL_FUNC']
peak = wline[wrange]
x0 = pix
cont = np.median(np.sort(wline)[0:3])
#cont = min(wline) # fare mediana dei tre punti piu' bassi
#if cont < 0:
# wline = wline - cont
# cont = 0
sigmagauss = 2.0
try:
......@@ -563,6 +566,8 @@ def UNe_calibrate(lamp,order,select_lines,all_lines,use_oliva=CONFIG['CAL_FUNC']
except:
#print 'gauss 1 failed'
#print select_lines[pixel]['wave']
true_pixel = 0.0
fwhm = 0.0
......@@ -645,6 +650,11 @@ def UNe_calibrate(lamp,order,select_lines,all_lines,use_oliva=CONFIG['CAL_FUNC']
x0 = wpos
#cont = min(wline)
cont = np.median(np.sort(wline)[0:3])
#if cont < 0:
# wline = wline - cont
# cont = 0
sigmagauss = 2.0
try:
......@@ -788,9 +798,9 @@ def UNe_calibrate(lamp,order,select_lines,all_lines,use_oliva=CONFIG['CAL_FUNC']
else:
print ' **** WARNING **** Order %s: not enough lines for the calibration!' % (str(order))
#print ' **** WARNING **** Order %s: not enough lines for the calibration!' % (str(order))
#calib = np.zeros(len(lamp))
messages.append('Calibration failed for order %s, not enough lines.' % (str(order),))
messages.append(' **** WARNING **** Calibration failed for order %s, not enough lines.' % (str(order),))
if use_oliva:
#coeffs = OrderedDict({'k1':None,'k2':None,'k3':None,'l0':None,'xc':None,'rms':None})
coeffs.update({'k1':None,'k2':None,'k3':None,'l0':None,'xc':None,'rms':None})
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment