




from typing import Dict, List, Optional, Union

import numpy as np

from ...image_processing_utils import BaseImageProcessor, BatchFeature, get_size_dict
from ...image_transforms import (
    center_crop,
    get_resize_output_image_size,
    normalize,
    rescale,
    resize,
    to_channel_dimension_format,
)
from ...image_utils import (
    IMAGENET_DEFAULT_MEAN,
    IMAGENET_DEFAULT_STD,
    ChannelDimension,
    ImageInput,
    PILImageResampling,
    is_batched,
    to_numpy_array,
    valid_images,
)
from ...utils import TensorType, logging


lowercase__				:     Optional[Any] 		=						logging.get_logger(__name__)
class 		UpperCAmelCase   (				UpperCAmelCase__			):







						'''simple docstring'''





						lowerCAmelCase_     		=   ['''pixel_values''']






						def __init__(						self							:     Union[str, Any]       ,	__lowercase							:     bool = True       ,	__lowercase							:     Optional[Dict[str, int]] = None       ,	__lowercase							:     PILImageResampling = PILImageResampling.BICUBIC       ,	__lowercase							:     bool = True       ,	__lowercase							:     bool = True       ,	__lowercase							:     Union[int, float] = 1 / 2_55       ,	__lowercase							:     Dict[str, int] = None       ,	__lowercase							:     bool = True       ,	__lowercase							:     Optional[Union[float, List[float]]] = None       ,	__lowercase							:     Optional[Union[float, List[float]]] = None       ,	**__lowercase							:     Optional[Any]       ,	):






							"""simple docstring"""






							super().__init__(**__lowercase						)
							snake_case_		    =     size if size is not None else {"height": 2_24, "width": 2_24}
							snake_case_		    =     get_size_dict(__lowercase						)
							snake_case_		    =     crop_size if crop_size is not None else {"height": 2_24, "width": 2_24}
							snake_case_		    =     get_size_dict(__lowercase       ,	default_to_square=__lowercase       ,	param_name="crop_size"						)

							snake_case_		    =     do_resize
							snake_case_		    =     do_rescale
							snake_case_		    =     do_normalize
							snake_case_		    =     do_center_crop
							snake_case_		    =     crop_size
							snake_case_		    =     size
							snake_case_		    =     resample
							snake_case_		    =     rescale_factor
							snake_case_		    =     image_mean if image_mean is not None else IMAGENET_DEFAULT_MEAN
							snake_case_		    =     image_std if image_std is not None else IMAGENET_DEFAULT_STD






						def        snake_case__						(						self							:     Dict       ,	__lowercase							:     np.ndarray       ,	__lowercase							:     Dict[str, int]       ,	__lowercase							:     PILImageResampling = PILImageResampling.BILINEAR       ,	__lowercase							:     Optional[Union[str, ChannelDimension]] = None       ,	**__lowercase							:     Tuple       ,	):






							"""simple docstring"""






							snake_case_		    =     get_size_dict(__lowercase						)

							if "shortest_edge" in size:
								snake_case_		    =     get_resize_output_image_size(__lowercase       ,	size=size["shortest_edge"]       ,	default_to_square=__lowercase						)
								# size = get_resize_output_image_size(image, size["shortest_edge"], size["longest_edge"])
							elif "height" in size and "width" in size:
								snake_case_		    =     (size["height"], size["width"])
							else:
								raise ValueError(f"Size must contain 'height' and 'width' keys or 'shortest_edge' key. Got {size.keys()}"						)
							return resize(__lowercase       ,	size=__lowercase       ,	resample=__lowercase       ,	data_format=__lowercase       ,	**__lowercase						)






						def        snake_case__						(						self							:     List[Any]       ,	__lowercase							:     np.ndarray       ,	__lowercase							:     Dict[str, int]       ,	__lowercase							:     Optional[Union[str, ChannelDimension]] = None       ,	**__lowercase							:     List[Any]       ,	):






							"""simple docstring"""






							snake_case_		    =     get_size_dict(__lowercase						)
							if "height" not in size or "width" not in size:
								raise ValueError(f"The `size` parameter must contain the keys (height, width). Got {size.keys()}"						)
							return center_crop(__lowercase       ,	size=(size["height"], size["width"])       ,	data_format=__lowercase       ,	**__lowercase						)






						def        snake_case__						(						self							:     List[str]       ,	__lowercase							:     np.ndarray       ,	__lowercase							:     float       ,	__lowercase							:     Optional[Union[str, ChannelDimension]] = None       ,	**__lowercase							:     Union[str, Any]						):






							"""simple docstring"""






							return rescale(__lowercase       ,	scale=__lowercase       ,	data_format=__lowercase       ,	**__lowercase						)






						def        snake_case__						(						self							:     str       ,	__lowercase							:     np.ndarray       ,	__lowercase							:     Union[float, List[float]]       ,	__lowercase							:     Union[float, List[float]]       ,	__lowercase							:     Optional[Union[str, ChannelDimension]] = None       ,	**__lowercase							:     Tuple       ,	):






							"""simple docstring"""






							return normalize(__lowercase       ,	mean=__lowercase       ,	std=__lowercase       ,	data_format=__lowercase       ,	**__lowercase						)






						def        snake_case__						(						self							:     Optional[int]       ,	__lowercase							:     ImageInput       ,	__lowercase							:     Optional[bool] = None       ,	__lowercase							:     Dict[str, int] = None       ,	__lowercase							:     PILImageResampling = None       ,	__lowercase							:     bool = None       ,	__lowercase							:     int = None       ,	__lowercase							:     Optional[bool] = None       ,	__lowercase							:     Optional[float] = None       ,	__lowercase							:     Optional[bool] = None       ,	__lowercase							:     Optional[Union[float, List[float]]] = None       ,	__lowercase							:     Optional[Union[float, List[float]]] = None       ,	__lowercase							:     Optional[Union[str, TensorType]] = None       ,	__lowercase							:     Union[str, ChannelDimension] = ChannelDimension.FIRST       ,	**__lowercase							:     Any       ,	):






							"""simple docstring"""






							snake_case_		    =     do_resize if do_resize is not None else self.do_resize
							snake_case_		    =     do_rescale if do_rescale is not None else self.do_rescale
							snake_case_		    =     do_normalize if do_normalize is not None else self.do_normalize
							snake_case_		    =     do_center_crop if do_center_crop is not None else self.do_center_crop
							snake_case_		    =     crop_size if crop_size is not None else self.crop_size
							snake_case_		    =     get_size_dict(__lowercase       ,	param_name="crop_size"       ,	default_to_square=__lowercase						)
							snake_case_		    =     resample if resample is not None else self.resample
							snake_case_		    =     rescale_factor if rescale_factor is not None else self.rescale_factor
							snake_case_		    =     image_mean if image_mean is not None else self.image_mean
							snake_case_		    =     image_std if image_std is not None else self.image_std

							snake_case_		    =     size if size is not None else self.size
							snake_case_		    =     get_size_dict(__lowercase						)

							if not is_batched(__lowercase						):
								snake_case_		    =     [images]

							if not valid_images(__lowercase						):
								raise ValueError(
								    "Invalid image type. Must be of type PIL.Image.Image, numpy.ndarray, "
								    "torch.Tensor, tf.Tensor or jax.ndarray."						)

							if do_resize and size is None:
								raise ValueError("Size must be specified if do_resize is True."						)

							if do_center_crop and crop_size is None:
								raise ValueError("Crop size must be specified if do_center_crop is True."						)

							if do_rescale and rescale_factor is None:
								raise ValueError("Rescale factor must be specified if do_rescale is True."						)

							# All transformations expect numpy arrays.
							snake_case_		    =     [to_numpy_array(__lowercase						) for image in images]

							if do_resize:
								snake_case_		    =     [self.resize(image=__lowercase       ,	size=__lowercase       ,	resample=__lowercase						) for image in images]

							if do_center_crop:
								snake_case_		    =     [self.center_crop(image=__lowercase       ,	size=__lowercase						) for image in images]

							if do_rescale:
								snake_case_		    =     [self.rescale(image=__lowercase       ,	scale=__lowercase						) for image in images]

							if do_normalize:
								snake_case_		    =     [self.normalize(image=__lowercase       ,	mean=__lowercase       ,	std=__lowercase						) for image in images]

							snake_case_		    =     [to_channel_dimension_format(__lowercase       ,	__lowercase						) for image in images]

							snake_case_		    =     {"pixel_values": images}
							return BatchFeature(data=__lowercase       ,	tensor_type=__lowercase						)






def 						lowerCamelCase__    (		):







	'''simple docstring'''





	snake_case_		    =     []
	snake_case_		    =     1

	while len(_A							) < 1E6:
		constant.append(str(_A							)							)
		i += 1

	snake_case_		    =     "".join(_A							)

	return (
	    int(constant[0]							)
	    * int(constant[9]							)
	    * int(constant[99]							)
	    * int(constant[999]							)
	    * int(constant[9999]							)
	    * int(constant[99999]							)
	    * int(constant[999999]							)
	)


if __name__ == "__main__":
		print(solution())
