class etspy.align.CommonLineAligner(etspy.align.StackAligner)[source]

Aligner class for common line (CL) strategy.

A combination of center of mass tracking for aligment of projections perpendicular to the tilt axis and common line alignment for parallel to the tilt axis. This is a Python implementation of Matlab code described in: M. C. Scott, et al. Electron tomography at 2.4-ångström resolution, Nature 483, 444-447 (2012). https://doi.org/10.1038/nature10934

start

Position in tilt series to use as starting point for the alignment. If None, the slice closest to the midpoint will be used.

Type:

py:class:~int

com_ref_index

Reference slice for center of mass alignment. All other slices will be aligned to this reference.

Type:

py:class:~int

cl_ref_index

Reference slice for common line alignment. All other slices will be aligned to this reference. If not provided the projection closest to the middle of the stack will be chosen.

Type:

py:class:~int

cl_resolution

Resolution for subpixel common line alignment. Default is 0.05. Should be less than 0.5.

Type:

py:class:~float

cl_div_factor

Factor which determines the number of iterations of common line alignment to perform. Default is 8.

Type:

py:class:~int

Constructors

CommonLineAligner(stack: TomoStack, start: int | None = 0, ...)[source]

Initialize self. See help(type(self)) for accurate signature.

Methods

calculate_shifts() ndarray[source]

Calculate shifts using combined center of mass and common line methods.

align(shift_method: 'interp' | 'fourier' = 'fourier') TomoStack[source]

Perform stack alignment.

align

calc_shifts_cl(cl_ref_index: int | None, ...) ndarray[source]

Calculate shifts using the common line method.

pad_line(line: ndarray, paddedsize: int) ndarray[source]

Pad a 1D array for FFT treatment without altering center location.