Performance is always important, but some algorithms are very expensive to apply to large picture sizes. To accommodate for this in Computer Vision we often need reduce an original image to a smaller size before we apply a given algorithm.
|tSrc||Tensor||The source image to be downsampled.|
|type?||string||Downsampling support two possible variants of processing|
pixels to be downsampled 'bicubic', 'nearest'.
// this line reduces an input image in 3x gm.downsample(inputImage, 3, 'nearest');