Esempio n. 1
0
#experiment_table=r"C:\Users\rbanderson\Documents\Projects\LIBS PDART\Input\Experiment_Setup_Table.csv"
#laser_table=r"C:\Users\rbanderson\Documents\Projects\LIBS PDART\Input\Laser_Setup_Table.csv"
#sample_table=r"C:\Users\rbanderson\Documents\Projects\LIBS PDART\Input\Sample_Table.csv"
#LUT_files={'spect':spect_table,'exp':experiment_table,'laser':laser_table,'sample':sample_table}
#data_dir=r"C:\Users\rbanderson\Documents\Projects\LIBS PDART\Sample_Data\LIBS USGS\DATA"
#JSC_data=jsc_batch(data_dir,LUT_files)
#JSC_data.to_csv('JSC_data.csv')
##Filter out just the Ti targets
#JSC_Ti=JSC_data.loc[np.squeeze(JSC_data['Sample ID'].isin(['TISDT01']))]

JSC_Ti=pd.read_csv(r"C:\Users\rbanderson\Documents\Projects\LIBS PDART\Output\JSC_Ti_data.csv",header=[0,1])
JSC_wvls=JSC_Ti['wvl'].columns.values


#Interpolate JSC data to CCAM data
JSC_Ti=interp_spect(JSC_Ti,xnew)


plot.figure()
plot.plot(JSC_wvls,JSC_Ti['wvl'].iloc[0,:])

JSC_Ti,JSC_bl=remove_baseline(JSC_Ti,method='als')
plot.plot(JSC_wvls,JSC_bl['wvl'].iloc[0,:])
plot.savefig('baseline_example.png',dpi=600)
plot.show()
##Combine JSC and CCAM Ti data
#data=pd.concat([JSC_Ti_interp,ccs_Ti])
#data.to_csv('JSC_CCS_Ti_data.csv')
#Mask spectra
JSC_Ti=mask(JSC_Ti,maskfile)
#Normalize Spectra
Esempio n. 2
0
 def interp(self,*args,**kwargs):
     return spectral_data(interp_spect(self.df,*args,**kwargs))