misc¶
tiatoolbox
.utils
.misc
Miscellaneous small functions repeatedly used in tiatoolbox.
Functions
Add annotations from a .dat file to an existing store. |
|
Helper function to create list of Annotation objects. |
|
Generate error if dtype is not int. |
|
Enhance contrast of the input image using intensity adjustment. |
|
Converts (and optionally saves) output of TIAToolbox engines as AnnotationStore. |
|
Saves the output of TIAToolbox engines to a zarr file. |
|
Download data from a given URL to location. |
|
Get bounding box coordinate information. |
|
Get tissue mask based on the luminosity of the input image. |
|
Grab file paths specified by file extensions. |
|
Read an image as numpy array. |
|
Write numpy array to an image. |
|
Load a stain matrix as a numpy array. |
|
Helper function to create a default typedict if none is provided. |
|
Helper function to make a valid polygon. |
|
Convert a string to a OpenCV (cv2) interpolation enum. |
|
Convert pixels per unit (ppu) to microns per pixel (mpp). |
|
Read annotations as pandas DataFrame. |
|
Save data to a json file. |
|
Save dictionary as yaml. |
|
Return appropriate interpolation method for opencv based image resize. |
|
Selects the appropriate device as requested. |
|
Split path of a file to directory path, file name and extensions. |
|
Load annotations from a hovernet-style .dat file. |
|
Splits input string to tuple at ','. |
|
Extract data from zip file. |