Commit 7bb82b3b94db7fbaedda91750b5aa9f523881469

Authored by Ilyes Choubani
1 parent ebbb68b1
Exists in master

remove lingering blank string

Showing 1 changed file with 8 additions and 9 deletions   Show diff stats
src/idl/dustem_read_fits_table.pro
... ... @@ -186,11 +186,13 @@ ENDELSE
186 186 used_model=strtrim(sxpar(main_header,'MODEL'),2)
187 187 used_pol=long(strtrim(sxpar(main_header,'POL'),2))
188 188 used_version=strtrim(sxpar(main_header,'WRAP_V'),2)
  189 +
189 190 IF used_model NE 'DEFAULT' THEN BEGIN
190   - dustem_init,model=used_model,pol=used_pol
  191 + dustem_init,model=used_model,pol=used_pol
191 192 ENDIF ELSE BEGIN
192   - dustem_init,model=0
  193 + dustem_init,model=0
193 194 ENDELSE
  195 +
194 196 !dustem_model=used_model
195 197 IF !dustem_version.version NE used_version THEN BEGIN
196 198 message,'Caution: fits file was not created with the same Dustemwrap version as your current version',/continue
... ... @@ -214,7 +216,7 @@ FOR i=0L,Nparams-1 DO BEGIN
214 216 best_parameters[i]=sxpar(main_header,'PARV'+strtrim(i+1,2))
215 217 best_parameters_uncertainties[i]=sxpar(main_header,'PARU'+strtrim(i+1,2))
216 218 best_parameters_init_values[i]=sxpar(main_header,'PARI'+strtrim(i+1,2))
217   - parameters_func_values[i]=sxpar(main_header,'PARI'+strtrim(i+1,2))
  219 + parameters_func_values[i]=sxpar(main_header,'PARF'+strtrim(i+1,2))
218 220 ENDFOR
219 221  
220 222 (*!dustem_fit).PARAM_DESCS=ptr_new(parameters_desc)
... ... @@ -225,16 +227,15 @@ ENDFOR
225 227 (*!dustem_fit).RCHI2=best_fit_rchi2
226 228 (*!dustem_fit).PARAM_FUNC=ptr_new(parameters_func_values)
227 229  
228   -
229   -;stop
230 230 ;==== This is to create (*!dustem_data).sed in case it does not exist already
  231 +; it doesn't exist at all times because dustem_init has been run
231 232 IF unit_input_emission_sed NE -1 THEN BEGIN
232 233 Nsed=n_elements(str_input_SED)
233 234 sed=dustem_initialize_internal_sed(Nsed)
234 235 (*!dustem_data).sed=ptr_new(sed)
235 236  
236 237 (*(*!dustem_data).sed).instru_names=dustem_filter2instru(str_input_SED.filter)
237   - (*(*!dustem_data).sed).filt_names=str_input_SED.filter
  238 + (*(*!dustem_data).sed).filt_names=strtrim(str_input_SED.filter,2)
238 239 (*(*!dustem_data).sed).wav=str_input_SED.wavelength
239 240 (*(*!dustem_data).sed).values=str_input_SED.I
240 241 (*(*!dustem_data).sed).sigma=str_input_SED.varianceII
... ... @@ -295,7 +296,7 @@ ENDELSE
295 296 dustem_predicted_em=mrdfits(file,unit_dustem_predicted_emission_spectra,header_predicted_emission)
296 297 dustem_predicted_ext= mrdfits(file,unit_dustem_predicted_extinction_spectra,header_predicted_extinction)
297 298  
298   -dustem_st.sed=dustem_predicted_em
  299 +dustem_st.sed=dustem_predicted_em
299 300 dustem_st.ext=dustem_predicted_ext
300 301  
301 302 IF used_pol THEN BEGIN
... ... @@ -306,8 +307,6 @@ IF used_pol THEN BEGIN
306 307 dustem_st.polext=toto
307 308 ENDIF
308 309  
309   -;stop
310   -
311 310 the_end:
312 311  
313 312 END
... ...