pineapple-core
pineapple-core defines functions and algorithms for reading, processing, and profilingbio-imaging datasets.
Supported image formats
pineapple currently supports 1 or 3 channel images of the following formats (plus experimental support for N-channel numpy images).
| Format | Dependencies |
|---|---|
jpeg/jpg |
image-rs |
png |
image-rs |
bmp |
image-rs |
tiff/tif |
image-rs |
hdr |
image-rs |
pbm |
image-rs |
avif |
image-rs |
tga |
image-rs |
qoi |
image-rs |
exr |
image-rs |
webp |
image-rs |
npy |
npyz |
Supported segmentation formats
pineapple currently supports reading and writing of masks, polygons, and bounding boxes.
| Format | Description |
|---|---|
| Binary mask | u8, u16, or u32 image where 0 indicates background and a positive integer indicates foreground. |
| Integer mask | u8, u16, or u32 image where 0 indicates background and unique positive integers specifiy different objects. |
| Polygons | (N, K, 2) json with a valid key: polygons, contours, outlines, shapes, points. |
| Bounding boxes | (N, [x_min, y_min, x_max, y_max]) json with a valid key: bounding_boxes, bboxes, bbox, bounding_box, boxes, xyxy. |
Future support
- Image formats
- N-channel
tiff/tifand N-channelzarrimages. - Optional compilation flag for bioformats (see rust bindings)
- N-channel
- Segmentation formats
- Additional formats for polygons or bounding boxes will be added on request (e.g.
npy).
- Additional formats for polygons or bounding boxes will be added on request (e.g.
- No planned support
- Three-dimensional imaging
- Gigapixel or whole-slide histology images (currently developing other crates for this - reach out if interested)
- Python bindings to the
pineapplelibrary (currently developing a python/rust specific library - reach out if interested)