Closed howardisaacson closed 10 months ago
@howardisaacson I'm getting the following error in the CI tests:
Traceback (most recent call last):
File "/code/KPF-Pipeline/kpfpipe/primitives/core.py", line 29, in apply
self.output = self._perform()
File "/code/KPF-Pipeline/modules/radial_velocity/src/radial_velocity_init.py", line 172, in _perform
init_result = self.alg_rv_init.start()
File "/code/KPF-Pipeline/modules/radial_velocity/src/alg_rv_init.py", line 734, in start
init_status = self.init_calculation()
File "/code/KPF-Pipeline/modules/radial_velocity/src/alg_rv_init.py", line 434, in init_calculation
self.get_mask_line() # based on mask_path, velocity loop and mask_width/vacuum_to_air
File "/code/KPF-Pipeline/modules/radial_velocity/src/alg_rv_init.py", line 685, in get_mask_line
air2vac)
File "/code/KPF-Pipeline/modules/radial_velocity/src/alg_rv_mask_line.py", line 47, in get_mask_line
air_to_vacuum)
File "/code/KPF-Pipeline/modules/radial_velocity/src/alg_rv_mask_line.py", line 76, in compute_mask_line
line_center, line_weight = np.loadtxt(mask_path, dtype=float, unpack=True) # load mask file
File "/usr/local/lib/python3.6/site-packages/numpy/lib/npyio.py", line 1139, in loadtxt
for x in read_data(_loadtxt_chunksize):
File "/usr/local/lib/python3.6/site-packages/numpy/lib/npyio.py", line 1067, in read_data
items = [conv(val) for (conv, val) in zip(converters, vals)]
File "/usr/local/lib/python3.6/site-packages/numpy/lib/npyio.py", line 1067, in <listcomp>
items = [conv(val) for (conv, val) in zip(converters, vals)]
File "/usr/local/lib/python3.6/site-packages/numpy/lib/npyio.py", line 763, in floatconv
return float(x)
ValueError: could not convert string to float: ',wave,weight'
I think that the old version of the file might not have had a header row?
The old version also has a header row. Both have an index column, which can be removed if needed. There are no letters (such as NaN) in the new file. Not clear what the problem is.
bfulton@shrek:static/stellarmasks $ head kpf_etalon_masks_11may2023.csv 4469.487482775782 1.0 4470.495206448418 1.0 4471.100813946687 1.0 4471.301039882537 1.0 4471.7052180587125 1.0 4471.907459527114 1.0 4472.108772045331 1.0
bfulton@shrek:static/stellarmasks $ head kpf_etalon_masks_30Oct2023.csv ,wave,weight 114,4470.849891466347,1 113,4471.226589223863,1 112,4471.415236512623,1 111,4471.789659604869,1 110,4471.977588677351,1
I went ahead and fixed it.
Updated etalon mask name.