[ 仅 API 调用方式不一致 ]torchvision.transforms.functional.adjust_contrast

torchvision.transforms.functional.adjust_contrast

torchvision.transforms.functional.adjust_contrast(img, contrast_factor)

paddle.vision.transforms.adjust_contrast

paddle.vision.transforms.adjust_contrast(img, contrast_factor)

两者功能一致,但调用方式不一致,具体如下:

转写示例

# PyTorch 写法
result = torchvision.transforms.functional.adjust_contrast(img, contrast_factor)

# Paddle 写法
result = paddle.vision.transforms.adjust_contrast(img, contrast_factor)