Click or drag to resize

WdfFileReader Class

Renishaw .wdf file reader. Renishaw WiRE (TM) .wdf files are used in Raman spectroscopy.
Inheritance Hierarchy
SystemObject
  Altaxo.Serialization.RenishawWdfFileReader

Namespace: Altaxo.Serialization.Renishaw
Assembly: AltaxoBase (in AltaxoBase.dll) Version: 4.8.3179.0 (4.8.3179.0)
Syntax
C#
public class WdfFileReader

The WdfFileReader type exposes the following members.

Constructors
 NameDescription
Public methodWdfFileReaderInitializes a new instance of the WdfFileReader class
Top
Properties
 NameDescription
Public propertyAccumulationCountNumber of accumulations used for one spectrum.
Public propertyApplicationNameName of the application that created this file.
Public propertyApplicationVersionVersion of the application that created this file.
Public propertyCapacityTotal number of experiments, can be greater than Count.
Public propertyCountNumber of experiments of the same type, can be smaller than Capacity.
Public propertyDataOriginCountNumber of rows in the data origin list.
Public propertyFileNameGets the name of the Wdf file.
Public propertyHasMapData Gets a value indicating whether this instance has map data.
Public propertyIsCompletedTrue if the number of spectra in this file equals the total number of spectra for this measurement.
Public propertyLaserWavelength_nmWavelength of the exciting laser in nm.
Public propertyMapShape 
Public propertyMeasurementTypeType of the measurement that created this file.
Public propertyNumberOfPointsPerSpectrumNumber of data points in each spectrum.
Public propertyOriginListHeader 
Public propertyScanTypeType of the scan that created this file.
Public propertySpectra 
Public propertySpectralUnitUnit of the y-values of the spectra.
Public propertyTitleTitle of the measurement.
Public propertyUserNameOperator of the measurement.
Public propertyXData 
Public propertyXPositions 
Public propertyXPositionUnit 
Public propertyXUnit 
Public propertyYData 
Public propertyYPositions 
Public propertyYPositionUnit 
Public propertyYUnit 
Public propertyZPositions 
Public propertyZPositionUnit 
Top
Methods
 NameDescription
Public methodEqualsDetermines whether the specified object is equal to the current object.
(Inherited from Object)
Protected methodFinalizeAllows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection.
(Inherited from Object)
Public methodStatic memberFromFileName 
Public methodStatic memberFromStream 
Public methodGetHashCodeServes as the default hash function.
(Inherited from Object)
Public methodGetSpectrum Gets the spectrum with index idx.
Public methodGetTypeGets the Type of the current instance.
(Inherited from Object)
Protected methodMemberwiseCloneCreates a shallow copy of the current Object.
(Inherited from Object)
Public methodToStringReturns a string that represents the current object.
(Inherited from Object)
Top
Remarks
Code inspired by Henderson, Alex DOI:10.5281/zenodo.495477, and by the Python implementation https://github.com/alchem0x2A/py-wdf-reader/blob/master/renishawWiRE/wdfReader.py
C#
The wdf file format is separated into several DataBlocks, with starting 4-char 
  strings such as (incomplete list):
    `WDF1`: File header for information
    `DATA`: Spectra data
    `XLST`: Data for X-axis of data, usually the Raman shift or wavelength
    `YLST`: Data for Y-axis of data, possibly not important
    `WMAP`: Information for mapping, e.g.StreamLine or StreamLineHR mapping
    `MAP `: Mapping information(?)
    `ORGN`: Data for stage origin
    `TEXT`: Annotation text etc
    `WXDA`: ? TODO
    `WXDM`: ? TODO
    `ZLDC`: ? TODO
    `BKXL`: ? TODO
    `WXCS`: ? TODO
    `WXIS`: ? TODO
    `WHTL`: Whilte light image
    Following the block name, there are two indicators:
    Block uid: int32
    Block size: int64
    Args:
    file_name(file) : File object for the wdf file
   Attributes:
    title(str) : Title of measurement
   username(str) : Username
  application_name(str) : Default WiRE
    application_version(int,) * 4 : Version number, e.g. [4, 4, 0, 6602]
   measurement_type(int) : Type of measurement
                             0=unknown, 1=single, 2=multi, 3=mapping
    scan_type(int) : Scan of type, see values in scan_types
   laser_wavenumber(float32) : Wavenumber in cm^-1
    count(int) : Numbers of experiments(same type), can be smaller than capacity
  spectral_units(int) : Unit of spectra, see unit_types
    xlist_type(int) : See unit_types
    xlist_unit(int) : See unit_types
    xlist_length(int) : Size for the xlist
    xdata(numpy.array) : x-axis data
    ylist_type(int) : Same as xlist_type
    ylist_unit(int): Same as xlist_unit
   ylist_length(int): Same as xlist_length
  ydata(numpy.array): y-data, possibly not used
 point_per_spectrum(int): Should be identical to xlist_length
data_origin_count(int) : Number of rows in data origin list
capacity(int) : Max number of spectra
    accumulation_count(int) : Single or multiple measurements
    block_info(dict) : Info block at least with following keys
                       DATA, XLST, YLST, ORGN
                        # TODO types?
See Also