1. Calibration (processor.utilities.calibration)
@author: Steinn Ymir Agustsson, Davide Curcio, Maciej Dendzik
- processor.utilities.calibration.correctOpticalPath(self, poly1=- 0.00020578, poly2=4.6813e-07, xCenter=1334, yCenter=1426)[source]
Apply corrections to the dataframe. (Maciej Dendzik)
Each DLD time is subtracted with a polynomial poly1*r + poly2*r^2, where r=sqrt((posx-xCenter)^2+(posy-yCenter)^2)
This function makes corrections to the time of flight which take into account the path difference between the center of the detector and the edges of the detector.
- processor.utilities.calibration.e2t(e, toffset=None, eoffset=None, l=0.77)[source]
Same as energy2tof, but different name for retrocompatibility
- Parameters:
- e: float
The binding energy
- toffset: float
The time offset from thedld clock start to when the fastest photoelectrons reach the detector
- eoffset: float
The energy offset given by W-hv-V
- l: float
the effective length of the drift section
- Return:
- t: float
The time of flight
- Authors:
Davide Curcio <davide.curcio@phys.au.dk>
- processor.utilities.calibration.energy2tof(e, toffset=None, eoffset=None, l=None)[source]
Transform eV to time of flight (ToF).
The functions (tof2energy and energy2tof) convert between binding energy (\(E_b\)) in eV (negative convention) and time of flight (ToF) in ns.
The formula used is based on the ToF for an electron with a kinetic energy \(E_k\). Then the binding energy \(E_b\) is given by
\[-E_b = E_k + W - hv - V = \frac{1}{2} mv^2 + W - hv - V\]With W the work function, hv the photon energy, V the electrostatic potential applied to the sample, v the velocity of the electrons in the drift tube, m the mass of the electron. The velocity v in the drift tube can be calculated knowing the length (1m) and the flight time in the drift tube. The measured ToF, however, has some offset due to clock start not coinciding with entry in the drift section.
offs is supposed to include the time offset for when the electrons enter the drift section. Its main mainly affects peak spacing, and there are several strategies for calibrating this value,
By measuring the photon peak and correcting by some extractor voltage-dependent offset
Shifting the potential by 1V and imposing the same shift in the measured spectrum
Imposing some calibrated spacing between features in a spectrum
eoffset is supposed to include -W+hv+V. It mainly affects absolute position of the peaks, and there are several strategies for calibrating this value,
By getting the correct values for W, hv, and V
It can be calibrated by imposing peak position
- Parameters:
- e: float
The binding energy
- toffset: float
The time offset from thedld clock start to when the fastest photoelectrons reach the detector
- eoffset: float
The energy offset given by W-hv-V
- l: float
the effective length of the drift section
- Return:
- t: float
The time of flight
- Authors:
Davide Curcio <davide.curcio@phys.au.dk>
- processor.utilities.calibration.filterCircleDLDPos(self, xCenter=1334, yCenter=1426, radius=1250)[source]
Apply corrections to the dataframe. (Maciej Dendzik)
Filters events with dldPosX and dldPosY within the radius from (xCenter,yCenter).
- processor.utilities.calibration.gen_sector_correction(prc, energies, eref, tofVoltage=None, sampleBias=None, monoEnergy=None)[source]
This function is helpful in generating the sector_correction list. This takes into account the time shift caused by the bit stealing hack plus is keeps track of the time shift due to detector misalignment by making sure all values of energies are at eref.
Usage: use the function to create the sector_correction list and assign it to prc.SECTOR_CORRECTION or paste it into the settings with no brackets
- Parameters
prc –
energies –
eref –
- Returns
- processor.utilities.calibration.shiftQuadrants(self, shiftQ1=0.231725, shiftQ2=- 0.221625, shiftQ3=0.096575, shiftQ4=- 0.106675, xCenter=1350, yCenter=1440)[source]
Apply corrections to the dataframe. (Maciej Dendzik)
Each quadrant of DLD is shifted in DLD time by shiftQn. xCenter and yCenter are used to define the center of the division.
Q2
Q4
Q1
Q3
This picture is upside-down in
plt.imshow
because it starts from 0 in top right corner.
- processor.utilities.calibration.t2e(t, toffset=None, eoffset=None, l=0.77)[source]
Same as tof2energy, but different name for retrocompatibility
- Parameters:
- t: float
The time of flight
- toffset: float
The time offset from thedld clock start to when the fastest photoelectrons reach the detector
- eoffset: float
The energy offset given by W-hv-V
- l: float
the effective length of the drift section
- Return:
- e: float
The binding energy
- Authors:
Davide Curcio <davide.curcio@phys.au.dk>
- processor.utilities.calibration.tof2energy(t, toffset=None, eoffset=None, l=None)[source]
Transform ToF to eV.
The functions (tof2energy and energy2tof) convert between binding energy (\(E_b\)) in eV (negative convention) and time of flight (ToF) in ns.
The formula used is based on the ToF for an electron with a kinetic energy \(E_k\). Then the binding energy \(E_b\) is given by
\[-E_b = E_k + W - hv - V = \frac{1}{2} mv^2 + W - hv - V\]With W the work function, hv the photon energy, V the electrostatic potential applied to the sample with respect to the drift section voltage, v the velocity of the electrons in the drift tube, m the mass of the electron.
The velocity v in the drift tube can be calculated knowing the length (1m) and the flight time in the drift tube. The measured ToF, however, has some offset due to clock start not coinciding with entry in the drift section.
toffset is supposed to include the time offset for when the electrons enter the drift section. Its main mainly affects peak spacing, and there are several strategies for calibrating this value,
By measuring the photon peak and correcting by some extractor voltage-dependent offset
Shifting the potential by 1V and imposing the same shift in the measured spectrum
Imposing some calibrated spacing between features in a spectrum
eoffset is supposed to include -W+hv+V. It mainly affects absolute position of the peaks, and there are several strategies for calibrating this value,
By getting the correct values for W, hv, and V
It can be calibrated by imposing peak position
- Parameters:
- t: float
The time of flight
- toffset: float
The time offset from thedld clock start to when the fastest photoelectrons reach the detector
- eoffset: float
The energy offset given by W-hv-V
- l: float
the effective length of the drift section
- Return:
- e: float
The binding energy
- Authors:
Davide Curcio <davide.curcio@phys.au.dk>