qbcompiler.calibration.preprocess.Resize Class Reference#
|
Mobilint SDK qb Compiler v1.2
MCS002-EN
|
qbcompiler.calibration.preprocess.Resize Class Reference
Resize images with optional aspect-ratio preservation. More...
Public Member Functions | |
| __init__ (self, Union[float, Tuple[int, int]] img_scale, bool keep_ratio, str interpolation) | |
| __call__ (self, np.ndarray img) | |
Public Attributes | |
| img_scale = img_scale | |
| keep_ratio = keep_ratio | |
| interpolation = interpolation | |
Detailed Description
Resize images with optional aspect-ratio preservation.
- Parameters
-
img_scale float or tuple[int, int]. Scaling factor or target size (h, w). keep_ratio bool. Preserve aspect ratio when True. Defaults to False. interpolation string. Interpolation mode ("nearest", "bilinear", "bicubic", "area", or "lanczos").
Definition at line 542 of file preprocess.py.
Constructor & Destructor Documentation
◆ __init__()
| qbcompiler.calibration.preprocess.Resize.__init__ | ( | self, | |
| Union[float, Tuple[int, int]] | img_scale, | ||
| bool | keep_ratio, | ||
| str | interpolation ) |
Definition at line 551 of file preprocess.py.
Member Function Documentation
◆ __call__()
| qbcompiler.calibration.preprocess.Resize.__call__ | ( | self, | |
| np.ndarray | img ) |
Definition at line 562 of file preprocess.py.
Member Data Documentation
◆ img_scale
| qbcompiler.calibration.preprocess.Resize.img_scale = img_scale |
Definition at line 558 of file preprocess.py.
◆ keep_ratio
| qbcompiler.calibration.preprocess.Resize.keep_ratio = keep_ratio |
Definition at line 559 of file preprocess.py.
◆ interpolation
| qbcompiler.calibration.preprocess.Resize.interpolation = interpolation |
Definition at line 560 of file preprocess.py.
The documentation for this class was generated from the following file:
Generated by