microcalorimetry.measurements.dcsweep

Created on Tue Oct 17 10:26:25 2023

@author: dcg2

Functions

run(→ str)

DCSweep experiment for microcalorimeter.

parse_v0(...)

Load and analyze the initial draft of a DC sweep run.

parse_v1(, off_min_wait, off_window, min_pwr_setting, ...)

Parse version 1 of a DC sweep calibration measurement.

Package Contents

microcalorimetry.measurements.dcsweep.run(config_files: list[pathlib.Path], runlist: pathlib.Path, output_dir: microcalorimetry._tkquick.gui_dtypes.Folder = '.', meas_name: str = 'dcsweep', dry_run: bool = False, validate: bool = True, initial_wait: float = 0) → str[source]

DCSweep experiment for microcalorimeter.

Source a series of voltages while monitoring the thermopile.

Parameters:
  • config_files (list[Path]) – Settings files for experiment.

  • runlist (Path) – Voltage measurment list for experiment.

  • output_dir (Folder) – Directory to output to, creates a DataRecord here the name meas_name,

  • meas_name (str, optional) – Name of measurement. Default is ‘dcsweep’.

  • dry_run (bool, optional) – If True, attempts to validate the measurement.

  • validate (bool, optional) – Validate settings against a schema.

  • initial_wait (float, optional) – Wait this long before starting a measurement. Will measure about zero source for this duration.

Returns:

path to metadata location of output file.

Return type:

str.

microcalorimetry.measurements.dcsweep.parse_v0(data_record: pathlib.Path, settings: pathlib.Path = None, measlist: pathlib.Path = None, on_time_window: float = 300, off_time_window: float = 300, heater_instr_name: str = 'SMU', sensor_instr_name: str = 'NVM', thermometer_instr_name: str = 'Thermometer', zero_threshhold: float = 1e-06, transition_threshhold_watts: float = 1e-05, make_plots: bool = True) → tuple[microcalorimetry.configs.ParsedDCSweep, list[matplotlib.pyplot.Figure]][source]

Load and analyze the initial draft of a DC sweep run.

Takes in a sensitivity experiment and generate sensitivity coefficients and other relevant data.

Parameters:
  • data_record (Path) – Path to data_record metadata file or folder.

  • settings (Path, optional) – Path to experiment settings. Assumed to be a file called settings.csv in metadata directory if not provided. The default is None.

  • measlist (Path, optional) – Path to experiment meas list. Assumed to be a file called measlist.csv in metadata directory if not provided. The default is None.

  • on_time_window (float, optional) – Time window for selecting on samples up to the end of the run. The default is 300.

  • off_time_window (float, optional) – Time window for selecting off samples up to the end of the run. The default is 300.

  • heater_instr_name (str, optional) – Name of heater instrument. The default is ‘SMU’.

  • sensor_instr_name (str, optional) – Name of sensor instrument. The default is ‘NVM’.

  • thermometer_instr_name (str, optional) – Name of the thermometer instrument. The default is ‘Thermometer’

  • zero_threshhold (float, optional) – Threshhold (in Watts) of samples below this where the heater is believed to be turned off. The default is 1e-6.

  • transition_threshhold_watts (float, optional) – Thresh hold (in Watts) where changes in the applied power to the heater constitutes a new step in the sweep. The default is 0.1e-4.

  • make_plots (bool, optional) – If true,make plots

Returns:

  • parsed_dc (configs.ParsedDCSweep) – ParsedCalibration object and any figures generated

  • sensitivity (configs.ThermolectricFitCoefficients) – Thermoelectric fit coefficients

  • figures (list[plt.Figure]) – Generated figures.

microcalorimetry.measurements.dcsweep.parse_v1(data_records: list[microcalorimetry._tkquick.gui_dtypes.Folder], thermopile_monitor: str, heater: str, on_min_wait: float = 1000, on_window: list[float] = (-600, 0), off_min_wait: float = 1000, off_window: list[float] = (-600, 0), min_pwr_setting: float = 0.0, thermometer_monitor: str = None, make_plots: bool = True) → tuple[microcalorimetry.configs.ParsedDCSweep, list[matplotlib.pyplot.Figure]][source]

Parse version 1 of a DC sweep calibration measurement.

Parameters:
  • data_records (list[Folder]) – List of paths to data_record files (or their folders) containing dcsweep measurements.

  • thermopile_monitor (str) – Name of thermopile monitor instrument.

  • heater (str, optional) – Name of heater instrument.

  • on_min_wait (float, optional) – Ignores data that hasn’t waited this long for selecting on samples.

  • on_window (list[float], optional) – positive numbers are relative to the beginning of the step, negative numbers are relative to the end of the step. [0, 100] = first 100 seconds of the step [-100, 0], last 100 seconds of the step [-100, -5], last 95 seconds of the step, ignoring last 5 [5, 100] from 5 to 100 seconds into the step.

  • off_min_wait (float, optional) – Ignores data that hasn’t waited this long for selecting off samples.

  • off_window (list[float], optional) – positive numbers are relative to the beginning of the step, negative numbers are relative to the end of the step. [0, 100] = first 100 seconds of the step [-100, 0], last 100 seconds of the step [-100, -5], last 95 seconds of the step, ignoring last 5 [5, 100] from 5 to 100 seconds into the step.

  • min_pwr_setting (float, optional) – Exclude and power levels below this value.

  • thermometer_monitor (str, optional, optional) – Name of instrument in the thermometer_monitor role. The default is None.

  • make_plots (bool, optional, optional) – Generates plots if asked. Default is True.

Returns:

  • parsed_dc (configs.ParsedDCSweep) – Parsed DC measurements.

  • figs (list[plt.Figure]) – Analysis Figures