sarcasm.meta_data_handler

Classes

MetaDataHandler

Module Contents

class sarcasm.meta_data_handler.MetaDataHandler(sarc_obj)[source]
sarc_obj
data_folder: pathlib.Path
static check_meta_data_exists(tif_file: str, channel: int | None) bool[source]
static extract_meta_data(tif_file: str, channel: int | None, use_gui: bool = False, info: Dict = {}) Tuple[int | None, Tuple[int, Ellipsis] | None, float | None, float | None, List | None][source]
static __get_shape_from_file(file: str, channel: int | None = None) Tuple[int | None, Tuple[int, Ellipsis] | None]
static __read_image(filename: str, channel: int | str | None = None, frame: int | None = None) numpy.ndarray

Load a TIFF file and optionally select a channel.

If channel is ‘RGB’, the image is converted to grayscale. Otherwise, if channel is an int, the specified channel is selected.

load_meta_data() None[source]
get_meta_data_file(is_temp_file: bool = False) pathlib.Path[source]
create_meta_data() None[source]
store_meta_data(override: bool = True) None[source]
commit() None[source]

Commit metadata by renaming the temporary file to the persistent file, ensuring an atomic update.