spectrochempy.read_carroucell
- read_carroucell(directory=None, **kwargs)[source]
Open
.spafiles in a directory after a carroucell experiment.The files for a given sample are grouped in `NDDataset`s (sorted by acquisition date). The `NDDataset`s are returned in a list sorted by sample number. When the file containing the temperature data is present, the temperature is read and assigned as a label to each spectrum.
- Parameters:
directory (
str, optional) – If not specified, opens a dialog box.**kwargs (keyword parameters, optional) – See Other Parameters.
- Returns:
object (
NDDatasetor list ofNDDataset) – The returned dataset(s).- Other Parameters:
spectra (array-like of 2
int(min,max), optional, default:None) – The first and last spectrum to be loaded as determined by their number. IfNoneall spectra are loaded.discardbg (
bool, optional, default:True) – IfTrue: do not load background (sample #9).delta_clocks (
int, optional, default: 0) – Difference in seconds between the clocks used for spectra and temperature acquisition. Defined ast(thermocouple clock) - t(spectrometer clock).
See also
readGeneric reader inferring protocol from the filename extension.
read_zipRead Zip archives (containing spectrochempy readable files)
read_dirRead an entire directory.
read_opusRead OPUS spectra.
read_labspecRead Raman LABSPEC spectra (
.txt).read_omnicRead Omnic spectra (
.spa,.spg,.srs).read_socRead Surface Optics Corps. files (
.ddr,.hdror.sdr).read_galacticRead Galactic files (
.spc).read_quaderaRead a Pfeiffer Vacuum’s QUADERA mass spectrometer software file.
read_topspinRead TopSpin Bruker NMR spectra.
read_csvRead CSV files (
.csv).read_jcampRead Infrared JCAMP-DX files (
.jdx,.dx).read_matlabRead Matlab files (
.mat,.dso).read_wireRead REnishaw Wire files (
.wdf).
Notes
All files are expected to be present in the same directory and their filenames are expected to be in the format :
X_samplename_YYY.spaand for the background files :X_BCKG_YYYBG.spawhereXis the sample holder number andYYYthe spectrum number.Examples
>>> scp.read_carroucell("irdata/carroucell_samp") no temperature file [NDDataset: [float64] a.u. (shape: (y:6, x:11098)), NDDataset: ...