Closed carys-evans closed 2 years ago
@carys-evans, I have updated the lines causing the issue, so just pull the changes. As you mention, it might have to do with the python version. Let's see if this fixes the problem. If it doesn't, do you mind sharing the images you are using to debug the pipeline?
The error was due to a division problem: in python3, x//y
produces the same output as x/y
in python2, i.e., an integer.
I have run into another issue with PESSTOEFOSC2dSPEC running on a new Mac. The following error appears after I have confirmed the biases and fitted the flats.
Traceback (most recent call last): File "/Users/carysevans/opt/anaconda3/envs/pessto/bin/PESSTOEFOSC2dSPEC", line 4, in
import('pkg_resources').run_script('ntt==3.0.0', 'PESSTOEFOSC2dSPEC')
File "/Users/carysevans/opt/anaconda3/envs/pessto/lib/python3.7/site-packages/pkg_resources/init.py", line 651, in run_script
self.require(requires)[0].run_script(script_name, ns)
File "/Users/carysevans/opt/anaconda3/envs/pessto/lib/python3.7/site-packages/pkg_resources/init.py", line 1448, in run_script
exec(code, namespace, namespace)
File "/Users/carysevans/opt/anaconda3/envs/pessto/lib/python3.7/site-packages/ntt-3.0.0-py3.7.egg/EGG-INFO/scripts/PESSTOEFOSC2dSPEC", line 112, in
listbias, listarc, _cosmic, _verbose)
File "/Users/carysevans/opt/anaconda3/envs/pessto/lib/python3.7/site-packages/ntt-3.0.0-py3.7.egg/ntt/efoscspec2Ddef.py", line 762, in efoscspecreduction
sigfrac=0.5, objlim=1, verbose=True, interactive=False)
File "/Users/carysevans/opt/anaconda3/envs/pessto/lib/python3.7/site-packages/ntt-3.0.0-py3.7.egg/ntt/cosmics.py", line 192, in lacos
arraygfirst = ntt.cosmics.my_convolve_with_FFT2(arrayfirst, gkernel)
File "/Users/carysevans/opt/anaconda3/envs/pessto/lib/python3.7/site-packages/ntt-3.0.0-py3.7.egg/ntt/cosmics.py", line 290, in my_convolve_with_FFT2
lside = np.empty((image1.shape[0], padc))
TypeError: 'float' object cannot be interpreted as an integer