Image Utils#
-
namespace trt_edgellm
-
namespace rt
-
namespace imageUtils
-
class ImageData#
- #include <imageUtils.h>
Image data container.
Wraps image tensor loaded with stbi. Expected shape: [height, width, channels]. Channels is typically 3 for RGB images.
Public Functions
-
ImageData(rt::Tensor &&data)#
Construct image data.
- Parameters:
data – Image tensor
- Throws:
std::runtime_error – if tensor content not UINT8, or tensor shape not 3D, or number of channels not 3
-
unsigned char *data() const noexcept#
Get raw image data pointer.
- Returns:
Pointer to image data
-
ImageData(rt::Tensor &&data)#
-
class ImageData#
-
namespace imageUtils
-
namespace rt