用法:
mxnet.image.scale_down(src_size, size)
- src_size:(
tuple of int
) - (寬度,高度)格式的圖像大小。 - size:(
tuple of int
) - (寬度,高度)格式的裁剪尺寸。
- src_size:(
包含 (width, height) 格式的縮放裁剪大小的元組。
int 的元組
參數:
返回:
返回類型:
如果裁剪大小大於圖像大小,則按比例縮小裁剪大小。
如果裁剪的寬度/高度大於圖像的寬度/高度,則將寬度/高度設置為圖像的寬度/高度。
示例:
>>> src_size = (640,480) >>> size = (720,120) >>> new_size = mx.img.scale_down(src_size, size) >>> new_size (640,106)
相關用法
- Python mxnet.image.resize_short用法及代碼示例
- Python mxnet.image.random_crop用法及代碼示例
- Python mxnet.image.imresize用法及代碼示例
- Python mxnet.image.center_crop用法及代碼示例
- Python mxnet.image.CreateAugmenter用法及代碼示例
- Python mxnet.image.ImageIter.read_image用法及代碼示例
- Python mxnet.image.CreateMultiRandCropAugmenter用法及代碼示例
- Python mxnet.image.imread用法及代碼示例
- Python mxnet.image.CreateDetAugmenter用法及代碼示例
- Python mxnet.image.ImageDetIter.sync_label_shape用法及代碼示例
- Python mxnet.image.ImageDetIter.draw_next用法及代碼示例
- Python mxnet.image.imdecode用法及代碼示例
- Python mxnet.io.PrefetchingIter用法及代碼示例
- Python mxnet.initializer.register用法及代碼示例
- Python mxnet.initializer.One用法及代碼示例
- Python mxnet.io.NDArrayIter用法及代碼示例
- Python mxnet.io.ResizeIter用法及代碼示例
- Python mxnet.initializer.Constant.dumps用法及代碼示例
- Python mxnet.initializer.Mixed用法及代碼示例
- Python mxnet.initializer.Zero用法及代碼示例
注:本文由純淨天空篩選整理自apache.org大神的英文原創作品 mxnet.image.scale_down。非經特殊聲明,原始代碼版權歸原作者所有,本譯文未經允許或授權,請勿轉載或複製。