delta.utils.XPReader¶
- class delta.utils.XPReader(path)[source]¶
Class to read experiment files from single files or from file sequences in folders.
- __init__(path)[source]¶
Initialize experiment reader.
- Parameters:
- pathPath or str
Path to experiment file or template to experiment files. If a template, it should contain the patterns {p}, {t}, or {c} to represent respectively position numbers, frame numbers, or channel numbers. The patterns can be repeated if the information is repeated in the file names. Valid examples: - “Pos{p}_Cha{c}_Fra{t}.tif” - “p{p}c{c}t{t}.tif” - “xy {p} - fluo {c} - timepoint {t} .TIFF” - “experiment_2023-05-11.nd2” - “multitiff_2023-05-11.tiff”
- Raises:
- ValueError
If the filenames in the experimental directory do not follow the correct format, a ValueError will be raised.
Methods
__init__(path)Initialize experiment reader.
image_path(position, channel, frame)Generate full filename for specific frame based on position, channel and frame.
images(position[, channels, frames, rotate])Get images from experiment.
Attributes
pathFile or folder name for the experiment
filetypeType / extension of filehandle
filehandleHandle to file reader or base directory
positionsPositions in the experiment
channelsImaging channels
channel_namesNames of the imaging channels (optional)
framesFrame numbers in the experiment
xSize of images along X axis
ySize of images along Y axis
dtypeDatatype of images