Auto-setup
Contents
Overview
The python-based auto-setup provides a more modular, flexible approach to tuning than the previous IDL code. The actions of acquisition, analysis, and plotting have been carefully separated. The analysis code has been centralized to reduce code duplication. Objects have been introduced to manage the locations of data and outputs to improve flexibility. Tools are provided to assist with loading and analyzing existing tuning data.
Currently the python auto-setup still relies on scripts such as ramp_sa_bias and the mux_lock C programs to acquire the tuning data. Inside the python environment, data is loaded and manipulated as numpy arrays.
Obtaining python auto_setup
As of this writing the python auto_setup is in a pre-alpha stage of development. It runs, however, so it will likely evolve quickly to be totally working. It can be obtained by checking out the py_auto_setup branch of mce_script:
svn checkout svn://e-mode.phas.ubc.ca/mce_script/branch/py_auto_setup
Script-level support
Pass "-h" to any of the scripts below to get a usage message.
auto_setup
The executable script auto_setup can be used to tune SQUID arrays from the command line.
plot_tuning
The executable script plot_tuning can be used create plots from existing tuning data.
The "auto_setup" module
The following classes may be useful for off-line analysis of tuning data. Note that the *Ramp and *Servo classes all inherit from the RCData class, takes a slightly eccentric approach to indexing the data it contains.
class SARamp
class SQ2Servo
class SQ1Servo
class SQ1Ramp
class RCData
This class stores time-ordered data for some set of detectors. Tuning data sets can be quite complex (consider a multi-bias, all-row SQ1 Servo for example) and so a certain convention has been adopted to indicate different structuring of the data. In all cases, the data themselves are stored in a 2-d numpy array, with the second index representing the time index and the first index encapsulating all other degrees of freedom (row, column, bias index,...). The underlying data shape is contained in the attribute data_shape. This is not to be confused with data.shape, which is the actual numpy dimensionality of the data array.
Form of data | data_shape | data.shape | gridded | rows | cols |
---|---|---|---|---|---|
One time-stream per channel | (n_row, n_col, n_time) | (n_row*n_col, n_time) | True | list of rows (size n_row) | list of columns (size n_col) |
Multi-bias data; n_bias time-stream per channel | (n_bias, n_row, n_col, n_time) | (n_bias*n_row*n_col, n_time) | True | list of rows (size n_chan) | list of columns (size n_chan) |
One time stream for some set of row, column pairs | (1, n_chan, n_time) | (n_chan, n_time) | False | list of rows (size n_chan) | list of columns (size n_chan) |
Multi-bias data; for some set of row, column pairs | (n_bias, 1, n_chan, n_time) | (n_bias*n_chan, n_time) | False | list of rows (size n_chan) | list of columns (size n_chan) |