diff --git a/bindings/python/cntk/io/__init__.py b/bindings/python/cntk/io/__init__.py index 09e20aeb2..9a8de8ee8 100644 --- a/bindings/python/cntk/io/__init__.py +++ b/bindings/python/cntk/io/__init__.py @@ -379,7 +379,7 @@ class ImageDeserializer(Deserializer): jitterType=jitter_type) @staticmethod - def scale(width, height, channels, interpolations='linear', scaleMode="fill", padValue=-1): + def scale(width, height, channels, interpolations='linear', scale_mode="fill", pad_value=-1): ''' Scale transform that can be used to pass to `map_features` for data augmentation. @@ -389,18 +389,18 @@ class ImageDeserializer(Deserializer): channels (int): channels of the image interpolations (str, default 'linear'): possible values are 'nearest', 'linear', 'cubic', and 'lanczos' - scaleMode (`str`, default 'center'): 'fill', 'crop' or 'pad'. + scale_mode (str, default 'fill'): 'fill', 'crop' or 'pad'. 'fill' - warp the image to the given target size. - 'crop' - resize the image's shorter side to the given target size and crops the overlap. + 'crop' - resize the image's shorter side to the given target size and crop the overlap. 'pad' - resize the image's larger side to the given target size, center it and pad the rest - padValue (`int`, default -1): -1 or int value. The pad value used for the 'pad' mode. + pad_value (int, default -1): -1 or int value. The pad value used for the 'pad' mode. If set to -1 then the border will be replicated. Returns: dict describing the scale transform ''' return dict(type='Scale', width=width, height=height, channels=channels, - interpolations=interpolations, scaleMode=scaleMode, padValue=padValue) + interpolations=interpolations, scaleMode=scale_mode, padValue=pad_value) @staticmethod def mean(filename):