135135=#
136136
137137try
138- mkpath (output_path )
138+ mkpath (input_path )
139139 global df_files = NEID. make_manifest (input_path) # joinpath(root_path,input_dir, subdir))
140140
141141catch ex
@@ -160,6 +160,23 @@ df_files_calib = df_files |>
160160df_files_calib[! ,:airmass ] = fill (NaN ,size (df_files_calib,1 ))
161161CSV. write (manifest_calib_filename, df_files_calib)
162162
163+ # Remove any files without exposure meter data
164+ # expmeter_cols = [:expmeter_mean, :expmeter_mean_blue, :expmeter_mean_green, :expmeter_mean_red, :expmeter_mean_winsor, :expmeter_rms, :expmeter_rms_blue, :expmeter_rms_green, :expmeter_rms_red, :expmeter_rms_winsor ]
165+ expmeter_mask = .! ismissing .(df_files. expmeter_mean)
166+ df_files = df_files[expmeter_mask,:]
167+
168+ # Deal with case of no telluric data
169+ df_files. telluric_zenith[isnothing .(df_files. telluric_zenith)] .= missing
170+ df_files. telluric_wvapor[isnothing .(df_files. telluric_wvapor)] .= missing
171+ if eltype (df_files. telluric_wvapor) == Union{Missing, Nothing} df_files. telluric_wvapor = fill (missing ,size (df_files,1 )) end
172+ if eltype (df_files. telluric_wvapor) == Union{Missing, Nothing, Float64}
173+ df_files. telluric_wvapor = convert .(Union{Missing, Float64}, df_files. telluric_wvapor)
174+ end
175+ if eltype (df_files. telluric_zenith) == Union{Missing, Nothing} df_files. telluric_zenith = fill (missing ,size (df_files,1 )) end
176+ if eltype (df_files. telluric_zenith) == Union{Missing, Nothing, Float64}
177+ df_files. telluric_zenith = convert .(Union{Missing, Float64}, df_files. telluric_zenith)
178+ end
179+
163180try
164181 global df_files_obs = df_files |>
165182 @filter ( _. target == " Sun" ) |>
0 commit comments