





'''simple docstring'''

import unittest
from pathlib import Path
from tempfile import TemporaryDirectory
from unittest.mock import Mock, patch

import diffusers.utils.hub_utils





class lowerCamelCase    (unittest.TestCase       ):







  @patch('''diffusers.utils.hub_utils.get_full_repo_name'''		)
  def 					UpperCAmelCase_					(		self  ,  lowercase__		)		->    None:






        """simple docstring"""





        _snake_case		:						List[str]         =  "full_repo_name"
        with TemporaryDirectory() as tmpdir:
              # Dummy args values
              _snake_case		:						Union[str, Any]         =  Mock()
              _snake_case		:						List[str]         =  tmpdir
              _snake_case		:						int         =  0
              _snake_case		:						int         =  "hub_token"
              _snake_case		:						int         =  "dataset_name"
              _snake_case		:						str         =  0.01
              _snake_case		:						List[Any]         =  100_000
              _snake_case		:						Dict         =  10_000
              _snake_case		:						Tuple         =  0.01
              _snake_case		:						Optional[int]         =  0.02
              _snake_case		:						Optional[Any]         =  0.03
              _snake_case		:						Union[str, Any]         =  0.0_005
              _snake_case		:						List[str]         =  0.000_001
              _snake_case		:						Dict         =  1
              _snake_case		:						List[str]         =  10
              _snake_case		:						Tuple         =  0.001
              _snake_case		:						Dict         =  0.1
              _snake_case		:						Optional[Any]         =  0.2
              _snake_case		:						List[Any]         =  True

              # Model card mush be rendered and saved
              diffusers.utils.hub_utils.create_model_card(__snake_case  ,  model_name='''model_name'''		)
              self.assertTrue((Path(__snake_case		) / '''README.md''').is_file()		)









from typing import TYPE_CHECKING

from ...utils import OptionalDependencyNotAvailable, _LazyModule, is_torch_available, is_vision_available


__lowerCAmelCase			:Optional[int]	 =     {
    'configuration_mobilenet_v1': [
        'MOBILENET_V1_PRETRAINED_CONFIG_ARCHIVE_MAP',
        'MobileNetV1Config',
        'MobileNetV1OnnxConfig',
    ],
}

try:
							if not is_vision_available():
														raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
							pass
else:
							__lowerCAmelCase			:Dict	 =     ['MobileNetV1FeatureExtractor']
							__lowerCAmelCase			:List[Any]	 =     ['MobileNetV1ImageProcessor']

try:
							if not is_torch_available():
														raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
							pass
else:
							__lowerCAmelCase			:Optional[int]	 =     [
							    'MOBILENET_V1_PRETRAINED_MODEL_ARCHIVE_LIST',
							    'MobileNetV1ForImageClassification',
							    'MobileNetV1Model',
							    'MobileNetV1PreTrainedModel',
							    'load_tf_weights_in_mobilenet_v1',
							]


if TYPE_CHECKING:
							from .configuration_mobilenet_va import (
							    MOBILENET_V1_PRETRAINED_CONFIG_ARCHIVE_MAP,
							    MobileNetVaConfig,
							    MobileNetVaOnnxConfig,
							)

							try:
														if not is_vision_available():
																					raise OptionalDependencyNotAvailable()
							except OptionalDependencyNotAvailable:
														pass
							else:
														from .feature_extraction_mobilenet_va import MobileNetVaFeatureExtractor
														from .image_processing_mobilenet_va import MobileNetVaImageProcessor

							try:
														if not is_torch_available():
																					raise OptionalDependencyNotAvailable()
							except OptionalDependencyNotAvailable:
														pass
							else:
														from .modeling_mobilenet_va import (
														    MOBILENET_V1_PRETRAINED_MODEL_ARCHIVE_LIST,
														    MobileNetVaForImageClassification,
														    MobileNetVaModel,
														    MobileNetVaPreTrainedModel,
														    load_tf_weights_in_mobilenet_va,
														)


else:
							import sys

							__lowerCAmelCase			:Optional[int]	 =     _LazyModule(__name__, globals()['__file__'], _import_structure, module_spec=__spec__)