autodeer.hardware.xepr_experiments

Module Contents

Classes

DEER

MPFUtune

Tuning MPFU channels for optimal attenuation and phase

ELDORtune

Tuning incoherent ELDOR channel for optimal power using nutation

PulseProfile

Tuning incoherent ELDOR channel for optimal power using nutation

Functions

get_nutations(api, nu, field, step[, ELDOR, nx])

CP_run(api, d0[, num_pulses, ps_length, sweeps, dt, ...])

DEER5p_run(api, ps_length, d0, tau2[, sweeps, ...])

CalibrateFreq(api[, num_points, deg])

Generate the polynomial parameters for converting from frequency

Attributes

autodeer.hardware.xepr_experiments.MODULE_DIR[source]
autodeer.hardware.xepr_experiments.get_nutations(api, nu, field, step, ELDOR=True, nx=128)[source]
Parameters:
  • ELDOR (bool)

  • nx (int)

autodeer.hardware.xepr_experiments.CP_run(api, d0, num_pulses=3, ps_length=16, sweeps=4, dt=100, num_points=256, srt=6000000.0)[source]
autodeer.hardware.xepr_experiments.DEER5p_run(api, ps_length, d0, tau2, sweeps=4, deadtime=80, dt=16, num_points=0, srt=6000000.0)[source]
class autodeer.hardware.xepr_experiments.DEER(api, d0, det_frq, pump_frq, srt=6000000.0)[source]
api[source]
d0[source]
det_frq[source]
pump_frq[source]
mpfu = 'True'[source]
hybrid = 'False'[source]
awg = 'False'[source]
srt[source]
run_5p(tau1, tau2, dt=16, deadtime=80, num_points=0, scans=200)[source]
Parameters:
  • tau1 (float)

  • tau2 (float)

  • dt (float)

  • deadtime (float)

  • num_points (int)

  • scans (int)

Return type:

None

run_4p(tau1, tau2, dt=16, deadtime=80, num_points=0, scans=200)[source]
Parameters:
  • tau1 (float)

  • tau2 (float)

  • dt (float)

  • deadtime (float)

  • num_points (int)

  • scans (int)

Return type:

None

run_CP(tau, dt=50, num_points=200, scans=1)[source]
Parameters:
  • tau (int)

  • dt (int)

  • num_points (int)

  • scans (int)

Return type:

None

class autodeer.hardware.xepr_experiments.MPFUtune(api, echo='Hahn', ps_length=16, d0=680, srt=6000000.0)[source]

Tuning MPFU channels for optimal attenuation and phase

Parameters:
api_type_

The spectrometr API object

echostr, optional

The echo type. Options = [‘Hahn”,”Refocused”], by default “Hahn”

ps_lengthint, optional

The length of the pi/2 pulse, by default 16

d0int, optional
The approximate position of d0, this should be lower than ideal,

by default 680

api[source]
hardware_wait = '5'[source]
ps_length[source]
d0[source]
srt[source]
_setup_echo(echo, tau1=400, tau2=400)[source]
tune_phase(channel, target, tol=0.1, maxiter=30)[source]

Tunes the phase of a given channel to a given target using the standard scipy optimisation scripts.

Parameters:
channelstr

The chosen MPFU channel. Options: [‘+<x>’, ‘-<x>’, ‘+<y>’, ‘-<y>’]

targetstr

The target echo position, this can either be maximising (+) or minimising (-) either the real (R) or imaginary (I) of the echo. Options: [‘R+’, ‘R-’, ‘I+’, ‘I-‘]

tolfloat, optional

The tolerance in phase parameter, by default 0.1

maxiterint, optional

The maximum number of iterations in the optimisation, by default 30

Returns:
float

The optimal value of the phase parameter

Parameters:
  • channel (str)

  • target (str)

Return type:

float

tune_power(channel, tol=0.1, maxiter=30, bounds=[0, 100])[source]

Tunes the attenuator of a given channel to a given target using the standard scipy optimisation scripts.

Parameters:
channelstr

The chosen MPFU channel. Options: [‘+<x>’, ‘-<x>’, ‘+<y>’, ‘-<y>’]

tolfloat, optional

The tolerance in attenuator parameter, by default 0.1

maxiterint, optional

The maximum number of iterations in the optimisation, by default 30

Returns:
float

The optimal value of the attenuator parameter

Parameters:
  • channel (str)

  • bounds (list[float])

Return type:

float

tune(channels, tol=0.1, bounds=[0, 100])[source]

Tunes both the power and attenuation for a collection of channels.

Parameters:
channelsdict

A dictionary of MPFU channels to be tunned and the associated phase target.Channel options = [‘+<x>’, ‘-<x>’, ‘+<y>’, ‘-<y>’]Phase target options = [‘R+’, ‘R-’, ‘I+’, ‘I-‘]E.g. {‘+<x>’: ‘R+’,’-<x>’: ‘R-‘}

tolfloat, optional

The tolerance for all optimisations, by default 0.1

Parameters:
  • channels (dict)

  • tol (float)

Return type:

None

calc_d0()[source]
class autodeer.hardware.xepr_experiments.ELDORtune(api, d0=700, ps_length=16, srt=6000000.0)[source]

Tuning incoherent ELDOR channel for optimal power using nutation experiments

Parameters:
apiXeprAPILink

The spectrometer API object

d0int, optional
The approximate position of d0, this should be lower than ideal,

by default 700

ps_lengthint, optional

The length of the pi/2 pulse, by default 16

Parameters:

api (autodeer.hardware.XeprAPILink)

api[source]
d0[source]
ps_length[source]
hardware_wait = '5'[source]
srt[source]
_setup_exp(tau1=400, tau2=400)[source]
_get_exp()[source]
find_min(dataset)[source]
tune(target)[source]
Parameters:

target (int)

class autodeer.hardware.xepr_experiments.PulseProfile(api, d0=700, ps_length=16, srt=4000000.0)[source]

Tuning incoherent ELDOR channel for optimal power using nutation experiments

Parameters:
apiXeprAPILink

The spectrometr API object

d0int, optional
The approximate position of d0, this should be lower than ideal,

by default 700

ps_lengthint, optional

The length of the pi/2 pulse, by default 16

Parameters:

api (autodeer.hardware.XeprAPILink)

api[source]
d0[source]
ps_length[source]
hardware_wait = '5'[source]
srt[source]
_setup_exp(tau=400)[source]

Setup the pulse profile experiment.

Parameters:
tauint, optional

The seperation between :math:’pi/2’ and :math:’pi’ in the Hahn echo, by default 400

_freq_sweep(nu, step, gyro)[source]

Run the frequency sweep for a pulse profile.

Parameters:
nulist

A list detailing the starting and ending frequency, [nu_init, nu_final]

stepfloat

The frequency step, given in GHz

gyrofloat

The gyromagnetic ratio in G/GHz.

Returns:
_type_

_description_

Parameters:
  • nu (list)

  • step (float)

  • gyro (float)

autodeer.hardware.xepr_experiments.CalibrateFreq(api, num_points=50, deg=5)[source]

Generate the polynomial parameters for converting from frequency (in GHz) to Xepr gunn diode stepper value. 0-4095.

Parameters:
apiXeprAPILink

The API for the spectrometer

num_pointsint, optional

The number of points to be measured, by default 50

degint, optional

The degree of polynomial fit, by default 5

Parameters:
  • api (autodeer.hardware.XeprAPILink)

  • num_points (int)

  • deg (int)