Skip to main content
. Author manuscript; available in PMC: 2021 Oct 19.
Published in final edited form as: Nat Protoc. 2021 Feb 22;16(3):1647–1713. doi: 10.1038/s41596-020-00478-x

Table 3 |.

Parameters for the ‘Fix Global Drift’ step in ChrTracer3

Parameter name Default value Function
selectFOVs inf You can choose to correct stage drift for specific FOVs by specifying them under SelectFOVs. If inf (infinite) all FOVs will be used
saveFits true Will save the coarse alignments
alignContrastLow 0.7 Auto contrast to enhance feature matching between images. Pixels dimmer than this fraction of the brightness histogram will be set to zero
alignContrastHigh 0.9995 Auto contrast to enhance feature matching between images. Pixels brighter than this fraction of the brightness histogram will be saturated
refReadout 1 As default, all fiducials are aligned with the Fiducial imaged simultaneously with Readout 1. If you want, you can choose to align all Fiducial images with any readout. For example, if you rather align Fiducials based on the Fiducial image taken simultaneously with Readout 2, change refReadout from ‘1’ to ‘2’
maxSize 400 All images will be downsampled to this size in terms of pixels for the coarse registration, prior to a second round of alignment on a subset of the image, at higher resolution. Set equal to image size or larger (‘inf’ is allowed) to do single step alignment
fineBox 100 Corresponds to the 100×100 pixel box size from the coarse alignment that will be used for fine alignment between fiducials from all FOVs. The fine alignment will use the brightest area of your image for this step
fineUpsample 1 The fine scale alignment can be performed to sub-pixel accuracy by upsampling each image. Values between ‘1’ (no upsampling) to ‘6’ (1/6 pixel accuracy) are recommended
maxShift inf This allows for shifts between fiducial images to occur during the coarse alignment without any shift restrictions
gradMax true Align where the gradient of the cross-correlation is largest (i.e. where the correlation strength changes the fastest, rather than where it is maximum). This typically performs better than maximizing the cross-correlation when aligning punctile data with varying brightness
minGrad -inf Optionally, select a minimum positive value for the gradient difference to accept the fine scale alignment. If this minimum improvement is not met, the maximum of the 2D cross-correlation function will be used instead of the gradient
angles 0 This refers to the angle of rotation potentially needed to drift correction. No angles need to be corrected here as the sample has not moved in a rotational manner during the experiment
scales 1 Isotropic expansion or contraction of image around the centroid. Typically not used here
fineMaxShift 10 Refers to the max shift in pixels that can be used for the fine alignment
fineAngles 0 If upsampling was used, the image can be corrected to sub-pixel resolution by scanning angles here. Typically not used here
fineScales 1 If upsampling was used, isotropic expansion can be corrected to sub-pixel accuracy by changing the scale here. Typically not used here
fineCenter [0 0] The computer will choose the best x-y position to do the fine alignment based on the pixel intensity of the fiducial spots. Optionally, this can be set to focus the fine-alignment on a particular pixel
showplot true This allows you to see Fig. 10b. It is not recommended to change this as visual inspection is always useful. However, if you decide to change this to ‘false’, you will be able to use MATLAB freely without the figure continuously appearing on your screen
fastDisplay true Downsample the overlay images displayed on the screen to the size specified by ‘displayWidth’. If the ‘maxSize’ is larger than the ‘displayWidth’, fastDisplay as ‘true’ will increase the run speed
displayWidth 500 If you wish to increase or decrease the display resolution of Fig. 10b, you can increase the size here and vice versa
showExtraPlot false Display the 2D correlation and gradient of the 2D correlation in addition to showing the alignment. Only recommended for troubleshooting
minFinelmprovement inf Optionally, require the absolute improvement in the correlation-coefficient of the fine alignment to be at least this much better than the correlation-coefficient of the coarse alignment. If this condition is not met, the coarse alignment values will be used and a warning message ‘fineAlign failed’ will be printed
showCorrAlign true This allows you to visualize the overlay of the corrected Fiducial for the latest readout corrected FOV