
import os
import sys
import unittest


UpperCAmelCase	      = os.path.abspath(os.path.dirname(os.path.dirname(os.path.dirname(__file__))))
sys.path.append(os.path.join(git_repo_path, '''utils'''))

import get_test_info  # noqa: E402
from get_test_info import (  # noqa: E402
    get_model_to_test_mapping,
    get_model_to_tester_mapping,
    get_test_to_tester_mapping,
)


UpperCAmelCase	      = os.path.join('''tests''', '''models''', '''bert''', '''test_modeling_bert.py''')
UpperCAmelCase	      = os.path.join('''tests''', '''models''', '''blip''', '''test_modeling_blip.py''')







class        A_   (			unittest.TestCase   ):




	'''simple docstring'''


	def 	SCREAMING_SNAKE_CASE__						(       self       ):
		lowercase       =    get_test_to_tester_mapping(UpperCamelCase_       )
		lowercase       =    get_test_to_tester_mapping(UpperCamelCase_       )

		lowercase       =    {'''BertModelTest''': '''BertModelTester'''}

		lowercase       =    {
		    '''BlipModelTest''': '''BlipModelTester''',
		    '''BlipTextImageModelTest''': '''BlipTextImageModelsModelTester''',
		    '''BlipTextModelTest''': '''BlipTextModelTester''',
		    '''BlipTextRetrievalModelTest''': '''BlipTextRetrievalModelTester''',
		    '''BlipVQAModelTest''': '''BlipVQAModelTester''',
		    '''BlipVisionModelTest''': '''BlipVisionModelTester''',
		}

		self.assertEqual(get_test_info.to_json(UpperCamelCase_       )		,    UpperCamelCase_       )
		self.assertEqual(get_test_info.to_json(UpperCamelCase_       )		,    UpperCamelCase_       )





	def 	SCREAMING_SNAKE_CASE__						(       self       ):
		lowercase       =    get_model_to_test_mapping(UpperCamelCase_       )
		lowercase       =    get_model_to_test_mapping(UpperCamelCase_       )

		lowercase       =    {
		    '''BertForMaskedLM''': ['''BertModelTest'''],
		    '''BertForMultipleChoice''': ['''BertModelTest'''],
		    '''BertForNextSentencePrediction''': ['''BertModelTest'''],
		    '''BertForPreTraining''': ['''BertModelTest'''],
		    '''BertForQuestionAnswering''': ['''BertModelTest'''],
		    '''BertForSequenceClassification''': ['''BertModelTest'''],
		    '''BertForTokenClassification''': ['''BertModelTest'''],
		    '''BertLMHeadModel''': ['''BertModelTest'''],
		    '''BertModel''': ['''BertModelTest'''],
		}

		lowercase       =    {
		    '''BlipForConditionalGeneration''': ['''BlipTextImageModelTest'''],
		    '''BlipForImageTextRetrieval''': ['''BlipTextRetrievalModelTest'''],
		    '''BlipForQuestionAnswering''': ['''BlipVQAModelTest'''],
		    '''BlipModel''': ['''BlipModelTest'''],
		    '''BlipTextModel''': ['''BlipTextModelTest'''],
		    '''BlipVisionModel''': ['''BlipVisionModelTest'''],
		}

		self.assertEqual(get_test_info.to_json(UpperCamelCase_       )		,    UpperCamelCase_       )
		self.assertEqual(get_test_info.to_json(UpperCamelCase_       )		,    UpperCamelCase_       )





	def 	SCREAMING_SNAKE_CASE__						(       self       ):
		lowercase       =    get_model_to_tester_mapping(UpperCamelCase_       )
		lowercase       =    get_model_to_tester_mapping(UpperCamelCase_       )

		lowercase       =    {
		    '''BertForMaskedLM''': ['''BertModelTester'''],
		    '''BertForMultipleChoice''': ['''BertModelTester'''],
		    '''BertForNextSentencePrediction''': ['''BertModelTester'''],
		    '''BertForPreTraining''': ['''BertModelTester'''],
		    '''BertForQuestionAnswering''': ['''BertModelTester'''],
		    '''BertForSequenceClassification''': ['''BertModelTester'''],
		    '''BertForTokenClassification''': ['''BertModelTester'''],
		    '''BertLMHeadModel''': ['''BertModelTester'''],
		    '''BertModel''': ['''BertModelTester'''],
		}

		lowercase       =    {
		    '''BlipForConditionalGeneration''': ['''BlipTextImageModelsModelTester'''],
		    '''BlipForImageTextRetrieval''': ['''BlipTextRetrievalModelTester'''],
		    '''BlipForQuestionAnswering''': ['''BlipVQAModelTester'''],
		    '''BlipModel''': ['''BlipModelTester'''],
		    '''BlipTextModel''': ['''BlipTextModelTester'''],
		    '''BlipVisionModel''': ['''BlipVisionModelTester'''],
		}

		self.assertEqual(get_test_info.to_json(UpperCamelCase_       )		,    UpperCamelCase_       )
		self.assertEqual(get_test_info.to_json(UpperCamelCase_       )		,    UpperCamelCase_       )





"""simple docstring"""





import numpy as np


def    _snake_case  (  _snake_case :	np.array	):
      return 1 / (1 + np.exp(-vector	))


if __name__ == "__main__":
 import doctest

 doctest.testmod()


