Module grpc_vision_svc::image_captioning::utils
source · Structs§
- A default implementation of the
DeviceUtils
trait. This implementation uses thecandle_core
crate to check if CUDA and Metal are available on the device (requires thecuda
ormetal
features to be enabled).
Traits§
- A trait for device utilities. Primarily used for DI & mocking in tests.
Functions§
- Creates a tensor from a byte slice representing pixel data.
- Selects the computing device based on the given preferences.
- Processes an image from raw bytes into an
ImageBuffer
of RGB values.