






"""simple docstring"""
import logging

from transformers import PretrainedConfig


snake_case : int     		=		logging.getLogger(__name__)


snake_case : List[str]     		=		{
    """bertabs-finetuned-cnndm""": """https://huggingface.co/remi/bertabs-finetuned-cnndm-extractive-abstractive-summarization/resolve/main/config.json""",
}



class        UpperCamelCase__ (				a_):







    """simple docstring"""
    __UpperCAmelCase           = """bertabs"""







    def __init__(		self :	Tuple				,    UpperCamelCase_ :	int=3_0_5_2_2				,    UpperCamelCase_ :	Any=5_1_2				,    UpperCamelCase_ :	str=6				,    UpperCamelCase_ :	List[Any]=5_1_2				,    UpperCamelCase_ :	Any=8				,    UpperCamelCase_ :	int=5_1_2				,    UpperCamelCase_ :	List[Any]=0.2				,    UpperCamelCase_ :	Optional[Any]=6				,    UpperCamelCase_ :	List[str]=7_6_8				,    UpperCamelCase_ :	str=8				,    UpperCamelCase_ :	Tuple=2_0_4_8				,    UpperCamelCase_ :	Optional[Any]=0.2				,    **UpperCamelCase_ :	Union[str, Any]				,    ):





           '''simple docstring'''

           super().__init__(**UpperCamelCase_ )

           __magic_name__      				=    vocab_size
           __magic_name__      				=    max_pos

           __magic_name__      				=    enc_layers
           __magic_name__      				=    enc_hidden_size
           __magic_name__      				=    enc_heads
           __magic_name__      				=    enc_ff_size
           __magic_name__      				=    enc_dropout

           __magic_name__      				=    dec_layers
           __magic_name__      				=    dec_hidden_size
           __magic_name__      				=    dec_heads
           __magic_name__      				=    dec_ff_size
           __magic_name__      				=    dec_dropout







"""simple docstring"""
from datetime import datetime

import matplotlib.pyplot as plt
import torch


def 							A						(				__snake_case: Optional[int]  )    ->		Tuple:

       """simple docstring"""





       for param in module.parameters():
              __magic_name__      				=    False


def 							A						(				)    ->		Optional[Any]:

       """simple docstring"""





       __magic_name__      				=    'cuda' if torch.cuda.is_available() else 'cpu'
       if torch.backends.mps.is_available() and torch.backends.mps.is_built():
              __magic_name__      				=    'mps'
       if device == "mps":
              print(
                  'WARNING: MPS currently doesn\'t seem to work, and messes up backpropagation without any visible torch'
                  ' errors. I recommend using CUDA on a colab notebook or CPU instead if you\'re facing inexplicable issues'
                  ' with generations.'  )
       return device


def 							A						(				__snake_case: int  )    ->		List[Any]:

       """simple docstring"""





       __magic_name__      				=    plt.imshow(__snake_case  )
       fig.axes.get_xaxis().set_visible(__snake_case  )
       fig.axes.get_yaxis().set_visible(__snake_case  )
       plt.show()






def 							A						(				)    ->		List[Any]:

       """simple docstring"""





       __magic_name__      				=    datetime.now()
       __magic_name__      				=    current_time.strftime('%H:%M:%S'  )
       return timestamp