Package reflectometry :: Package reduction :: Module icpformat :: Class ICP

Class ICP

source code


Instance Methods
 
__init__(self, path)
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
source code
 
readheader1(self)
Read the tow line summary at the start of the ICP data files.
source code
 
readiheader(self)
Read I-buffer structure, excluding motors.
source code
 
readrheader(self)
Read R-buffer structure, excluding motors.
source code
 
readqheader(self)
Read Q-buffer structure.
source code
 
check_wavelength(self, default, overrides)
ICP sometimes records the incorrect wavelength in the file.
source code
 
readmotors(self)
Read the 6 motor lines, returning a dictionary of motor names and start-step-stop values.
source code
 
readcolumnheaders(self)
Get a list of column names.
source code
 
readcolumns(self)
Read and parse ICP data columns listed in columns.
source code
 
genmotorcolumns(self)
Generate vectors for each of the motors if a vector is not already stored in the file.
source code
 
parseheader(self)
Read and parse ICP header information
source code
 
summary(self)
Read header from file, returning a dict of fields.
source code
 
read(self)
Read header and data from file, returning a dict of fields.
source code
 
__contains__(self, column) source code
 
counts(self) source code

Inherited from object: __delattr__, __getattribute__, __hash__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __str__

Properties

Inherited from object: __class__

Method Details

__init__(self, path)
(Constructor)

source code 
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
Overrides: object.__init__
(inherited documentation)

check_wavelength(self, default, overrides)

source code 
ICP sometimes records the incorrect wavelength in the file. Make sure the right value is being used. Be annoying about it so that if the wavelength was changed for a legitimate reason the user can override. L is the value in the file. dectector.wavelength should already be set to the default for the instrument.

readmotors(self)

source code 

Read the 6 motor lines, returning a dictionary of motor names and start-step-stop values. E.g.,

M = _readmotors(file) print M['a1'].start

readcolumnheaders(self)

source code 

Get a list of column names. Transform the names of certain
columns to make our lives easier elsewhere:
      #1 COUNTS -> counts
      #2 COUNTS -> counts2
      MON -> monitor
      MIN -> time
      Q(x) -> qx, Q(y) -> qy, Q(z) -> qz
All column names are uppercase.

readcolumns(self)

source code 
Read and parse ICP data columns listed in columns. Return a dict of column name: vector. If using a position sensitive detector, return an array of detector values x scan points.