ResizedImageInfo
Description
Records the resizing mode used during model preprocessing in an image task, which is then provided for coordinate restoration during model postprocessing.
Structure Definition
1 2 3 4 5 6 7 8 9 10 11 12 13 14 | class ResizedImageInfo { public: ResizedImageInfo() {} ResizedImageInfo(uint32_t wResize, uint32_t hResize, uint32_t wOriginal, uint32_t hOriginal, ResizeType rType, float kARScaling) : widthResize(wResize), heightResize(hResize), widthOriginal(wOriginal), heightOriginal(hOriginal), resizeType(rType), keepAspectRatioScaling(kARScaling) {} uint32_t widthResize = 0; uint32_t heightResize = 0; uint32_t widthOriginal = 0; uint32_t heightOriginal = 0; ResizeType resizeType = RESIZER_STRETCHING; float keepAspectRatioScaling = 0; }; |
Parameters
Parameter |
Description |
|---|---|
widthResize |
Width of the resized image, that is, the input width of the model |
heightResize |
Height of the resized image, that is, the input height of the model |
widthOriginal |
Image width prior to resizing |
heightOriginal |
Image height prior to resizing |
resizeType |
Image resizing mode (enumeration):
|
keepAspectRatioScaling |
Ratio for resizing with the aspect ratio preserved. This parameter is valid only for resizing with the aspect ratio preserved. |
Parent topic: General Data Structures