GS::Utils::Image
Image class for loaded images
Constructors
Instance methods
channels
Sourcedata
Sourceheight
Sourceto_tensor(device : Tensor::Device = Tensor::Device::CPU) : Tensor
Convert to tensor [height, width, channels] normalized to 0-1
to_tensor_bchw(device : Tensor::Device = Tensor::Device::CPU) : Tensor
Convert to tensor with batch dimension [1, channels, height, width]
to_tensor_chw(device : Tensor::Device = Tensor::Device::CPU) : Tensor
Convert to tensor [channels, height, width] (CHW format) normalized to 0-1
width
Source