Expand description
Image loading and preprocessing utilities for multimodal models
This module provides utilities for:
- Loading images from disk (PNG, JPEG, etc.)
- Preprocessing images for vision encoders
- Creating fallback minimal images
- Batch image processing
Structs§
- Image
Input - Image data structure for passing around
- Image
Preprocess Config - Image preprocessing configuration
Functions§
- batch_
images - Batch multiple images into a single tensor
- create_
fallback_ image - Create a minimal fallback image (1x1 random pixel expanded to full size)
- load_
image - Load an image from disk and preprocess it for vision encoder
- load_
image_ from_ bytes - Load an image from raw bytes (PNG, JPEG, or other formats supported by
imagecrate) - load_
images - Load multiple images and batch them