I/O
Functions:
|
Detects the extension and loads image into a numpy array if it's a tif/tiff or an asc file. |
|
Loads the data of an SDT file, reshaping the output is necessary as this outputs a 1d array. |
|
Loads an sdt file and attemps to reshape the data into a cube corresponding to common file shapes. |
|
Reads in an asc file into a numpy ndarray |
- cell_analysis_tools.io.load_image(path: str | PurePath) ndarray[source]
Detects the extension and loads image into a numpy array if it’s a tif/tiff or an asc file.
- Parameters:
path (pathlib path or str) – path to the image.
- Returns:
ndarray with the image data.
- Return type:
np.ndarray
- cell_analysis_tools.io.load_sdt_data(filepath)[source]
Loads the data of an SDT file, reshaping the output is necessary as this outputs a 1d array.
- Parameters:
filepath (string, pathlib path) – path to the input image
- Returns:
data – 1D array containing all channel and pixel data
- Return type:
np.ndarray