


"""simple docstring"""


from typing import List, Optional, Union

from ...image_utils import ImageInput
from ...processing_utils import ProcessorMixin
from ...tokenization_utils_base import BatchEncoding, PaddingStrategy, PreTokenizedInput, TextInput, TruncationStrategy
from ...utils import TensorType
class snake_case      (  _UpperCamelCase):
		__UpperCamelCase           =			['image_processor', 'tokenizer']
		__UpperCamelCase           =			'BlipImageProcessor'
		__UpperCamelCase           =			('BertTokenizer', 'BertTokenizerFast')







		def __init__(					self      :       str    ,   a__      :       Any    ,   a__      :       int		)       ->						str:





						'''simple docstring'''







						_A					  =			False
						super().__init__(a__    ,   a__		)
						_A					  =			self.image_processor







		def __call__(					self      :       List[Any]    ,   a__      :       ImageInput = None    ,   a__      :       Union[TextInput, PreTokenizedInput, List[TextInput], List[PreTokenizedInput]] = None    ,   a__      :       bool = True    ,   a__      :       Union[bool, str, PaddingStrategy] = False    ,   a__      :       Union[bool, str, TruncationStrategy] = None    ,   a__      :       Optional[int] = None    ,   a__      :       int = 0    ,   a__      :       Optional[int] = None    ,   a__      :       Optional[bool] = None    ,   a__      :       bool = False    ,   a__      :       bool = False    ,   a__      :       bool = False    ,   a__      :       bool = False    ,   a__      :       bool = False    ,   a__      :       bool = True    ,   a__      :       Optional[Union[str, TensorType]] = None    ,   **a__      :       Dict    ,   )       ->						BatchEncoding:





						'''simple docstring'''







						if images is None and text is None:
										raise ValueError("You have to specify either images or text."		)

						# Get only text
						if images is None:
										_A					  =			self.tokenizer
										_A					  =			self.tokenizer(
										    text=a__    ,   add_special_tokens=a__    ,   padding=a__    ,   truncation=a__    ,   max_length=a__    ,   stride=a__    ,   pad_to_multiple_of=a__    ,   return_attention_mask=a__    ,   return_overflowing_tokens=a__    ,   return_special_tokens_mask=a__    ,   return_offsets_mapping=a__    ,   return_token_type_ids=a__    ,   return_length=a__    ,   verbose=a__    ,   return_tensors=a__    ,   **a__    ,   )
										return text_encoding

						# add pixel_values
						_A					  =			self.image_processor(a__    ,   return_tensors=a__		)

						if text is not None:
										_A					  =			self.tokenizer(
										    text=a__    ,   add_special_tokens=a__    ,   padding=a__    ,   truncation=a__    ,   max_length=a__    ,   stride=a__    ,   pad_to_multiple_of=a__    ,   return_attention_mask=a__    ,   return_overflowing_tokens=a__    ,   return_special_tokens_mask=a__    ,   return_offsets_mapping=a__    ,   return_token_type_ids=a__    ,   return_length=a__    ,   verbose=a__    ,   return_tensors=a__    ,   **a__    ,   )
						else:
										_A					  =			None

						if text_encoding is not None:
										encoding_image_processor.update(a__		)

						return encoding_image_processor







		def  a_ (					self      :       Optional[int]    ,   *a__      :       int    ,   **a__      :       Tuple		)       ->						List[Any]:





						'''simple docstring'''







						return self.tokenizer.batch_decode(*a__    ,   **a__		)







		def  a_ (					self      :       List[Any]    ,   *a__      :       List[str]    ,   **a__      :       Optional[Any]		)       ->						Any:





						'''simple docstring'''







						return self.tokenizer.decode(*a__    ,   **a__		)







		@property
		def  a_ (					self      :       Union[str, Any]		)       ->						Optional[Any]:





						'''simple docstring'''







						_A					  =			self.tokenizer.model_input_names
						_A					  =			self.image_processor.model_input_names
						return list(dict.fromkeys(tokenizer_input_names + image_processor_input_names		)		)






"""simple docstring"""


from __future__ import annotations






def      a__ (				__lowercase     ,			__lowercase   )	->	float:
				_A					  =			sorted(numsa + numsa   )
				_A  ,		_A					  =			divmod(len(__lowercase   )     ,			2   )
				if mod == 1:
								return all_numbers[div]
				else:
								return (all_numbers[div] + all_numbers[div - 1]) / 2


if __name__ == "__main__":
		import doctest

		doctest.testmod()
		a_       							=    [float(x) for x in input("Enter the elements of first array: ").split()]
		a_       							=    [float(x) for x in input("Enter the elements of second array: ").split()]
		print(f'''The median of two arrays is: {median_of_two_arrays(array_a, array_a)}''')