class StackParams: (source)
Constructor: StackParams(stack_dz, images_to_save, min_images_to_test, autofocus_dz, ...)
A class for holding for stack parameters, and returning computed ones.
| Method | __init__ |
Initialise the parameters. All arguments are keyword only. |
| Method | slice |
Return the slice of images to save given the index of the sharpest image. |
| Class Variable | backlash |
Distance (in steps) to overshoot a move and then undo, to account for backlash |
| Class Variable | img |
How far below (in factors of stack_dz) the estimated optimal starting position to begin the stack. Better to start slightly too low and require many images, rather than too high and needing to autofocus and restart the stack... |
| Class Variable | max |
Maximum number of times to attempt fast stack |
| Class Variable | settling |
Time (in seconds) between moving and capturing an image |
| Class Variable | stack |
How many images can be appended to the stack after the predicted peak to test for focus before assuming the focus was passed, and restarting the stack |
| Instance Variable | autofocus |
Undocumented |
| Instance Variable | images |
Undocumented |
| Instance Variable | images |
Undocumented |
| Instance Variable | min |
Undocumented |
| Instance Variable | save |
Undocumented |
| Instance Variable | stack |
Undocumented |
| Property | max |
The maximum number of images that will be captured and tested in a stack. |
| Property | stack |
The range of the z stack, in steps. |
| Property | steps |
The distance to deliberately undershoot the estimated optimal starting point. |
int, images_to_save: int, min_images_to_test: int, autofocus_dz: int, images_dir: str, save_resolution: tuple[ int, int]):
(source)
¶
Initialise the parameters. All arguments are keyword only.
| Parameters | |
stackint | The number of motor steps between images |
imagesint | The number of images to save to disk |
minint | The minimum number of images in the stack before, the stack is evaluated for focus. As more images are captured evaluation of the focus is always evaluated with the same number of images. i.e. if min_images_to_test=9, then 9 images are captured, if the stack is not well focused, a 10th image is captured and images 2 to 10 are evaluated for focus |
autofocusint | The number of steps in a full autofocus (when required) |
imagesstr | The directory to save images to disk |
savetuple[ | The resolution to save the captures to disk with |
How far below (in factors of stack_dz) the estimated optimal starting position to begin the stack. Better to start slightly too low and require many images, rather than too high and needing to autofocus and restart the stack
How many images can be appended to the stack after the predicted peak to test for focus before assuming the focus was passed, and restarting the stack
The maximum number of images that will be captured and tested in a stack.
This is 15 images more then the minimum number that are captured.