
import unittest

from diffusers.pipelines.pipeline_utils import is_safetensors_compatible

class 							_UpperCamelCase					(       unittest.TestCase	):






			'''simple docstring'''

			def    lowerCAmelCase__						(							self			:							str   ):
							UpperCamelCase_:				int						=    [
							    """safety_checker/pytorch_model.bin""",
							    """safety_checker/model.safetensors""",
							    """vae/diffusion_pytorch_model.bin""",
							    """vae/diffusion_pytorch_model.safetensors""",
							    """text_encoder/pytorch_model.bin""",
							    """text_encoder/model.safetensors""",
							    """unet/diffusion_pytorch_model.bin""",
							    """unet/diffusion_pytorch_model.safetensors""",
							]
							self.assertTrue(is_safetensors_compatible(snake_case_   )   )

			def    lowerCAmelCase__						(							self			:							Optional[Any]   ):
							UpperCamelCase_:				int						=    [
							    """unet/diffusion_pytorch_model.bin""",
							    """unet/diffusion_pytorch_model.safetensors""",
							]
							self.assertTrue(is_safetensors_compatible(snake_case_   )   )

			def    lowerCAmelCase__						(							self			:							str   ):
							UpperCamelCase_:				Dict						=    [
							    """safety_checker/pytorch_model.bin""",
							    """safety_checker/model.safetensors""",
							    """vae/diffusion_pytorch_model.bin""",
							    """vae/diffusion_pytorch_model.safetensors""",
							    """text_encoder/pytorch_model.bin""",
							    """text_encoder/model.safetensors""",
							    """unet/diffusion_pytorch_model.bin""",
							    # Removed: 'unet/diffusion_pytorch_model.safetensors',
							]
							self.assertFalse(is_safetensors_compatible(snake_case_   )   )

			def    lowerCAmelCase__						(							self			:							Tuple   ):
							UpperCamelCase_:				Dict						=    [
							    """text_encoder/pytorch_model.bin""",
							    """text_encoder/model.safetensors""",
							]
							self.assertTrue(is_safetensors_compatible(snake_case_   )   )

			def    lowerCAmelCase__						(							self			:							Tuple   ):
							UpperCamelCase_:				List[str]						=    [
							    """safety_checker/pytorch_model.bin""",
							    """safety_checker/model.safetensors""",
							    """vae/diffusion_pytorch_model.bin""",
							    """vae/diffusion_pytorch_model.safetensors""",
							    """text_encoder/pytorch_model.bin""",
							    # Removed: 'text_encoder/model.safetensors',
							    """unet/diffusion_pytorch_model.bin""",
							    """unet/diffusion_pytorch_model.safetensors""",
							]
							self.assertFalse(is_safetensors_compatible(snake_case_   )   )

			def    lowerCAmelCase__						(							self			:							Any   ):
							UpperCamelCase_:				Any						=    [
							    """safety_checker/pytorch_model.fp16.bin""",
							    """safety_checker/model.fp16.safetensors""",
							    """vae/diffusion_pytorch_model.fp16.bin""",
							    """vae/diffusion_pytorch_model.fp16.safetensors""",
							    """text_encoder/pytorch_model.fp16.bin""",
							    """text_encoder/model.fp16.safetensors""",
							    """unet/diffusion_pytorch_model.fp16.bin""",
							    """unet/diffusion_pytorch_model.fp16.safetensors""",
							]
							UpperCamelCase_:				str						=    """fp16"""
							self.assertTrue(is_safetensors_compatible(snake_case_    ,						variant=snake_case_   )   )

			def    lowerCAmelCase__						(							self			:							int   ):
							UpperCamelCase_:				Tuple						=    [
							    """unet/diffusion_pytorch_model.fp16.bin""",
							    """unet/diffusion_pytorch_model.fp16.safetensors""",
							]
							UpperCamelCase_:				List[Any]						=    """fp16"""
							self.assertTrue(is_safetensors_compatible(snake_case_    ,						variant=snake_case_   )   )

			def    lowerCAmelCase__						(							self			:							Optional[Any]   ):
							# pass variant but use the non-variant filenames
							UpperCamelCase_:				Tuple						=    [
							    """unet/diffusion_pytorch_model.bin""",
							    """unet/diffusion_pytorch_model.safetensors""",
							]
							UpperCamelCase_:				List[Any]						=    """fp16"""
							self.assertTrue(is_safetensors_compatible(snake_case_    ,						variant=snake_case_   )   )

			def    lowerCAmelCase__						(							self			:							Dict   ):
							UpperCamelCase_:				List[Any]						=    [
							    """safety_checker/pytorch_model.fp16.bin""",
							    """safety_checker/model.fp16.safetensors""",
							    """vae/diffusion_pytorch_model.fp16.bin""",
							    """vae/diffusion_pytorch_model.fp16.safetensors""",
							    """text_encoder/pytorch_model.fp16.bin""",
							    """text_encoder/model.fp16.safetensors""",
							    """unet/diffusion_pytorch_model.fp16.bin""",
							    # Removed: 'unet/diffusion_pytorch_model.fp16.safetensors',
							]
							UpperCamelCase_:				str						=    """fp16"""
							self.assertFalse(is_safetensors_compatible(snake_case_    ,						variant=snake_case_   )   )

			def    lowerCAmelCase__						(							self			:							Any   ):
							UpperCamelCase_:				List[str]						=    [
							    """text_encoder/pytorch_model.fp16.bin""",
							    """text_encoder/model.fp16.safetensors""",
							]
							UpperCamelCase_:				Tuple						=    """fp16"""
							self.assertTrue(is_safetensors_compatible(snake_case_    ,						variant=snake_case_   )   )

			def    lowerCAmelCase__						(							self			:							List[str]   ):
							# pass variant but use the non-variant filenames
							UpperCamelCase_:				Union[str, Any]						=    [
							    """text_encoder/pytorch_model.bin""",
							    """text_encoder/model.safetensors""",
							]
							UpperCamelCase_:				Optional[Any]						=    """fp16"""
							self.assertTrue(is_safetensors_compatible(snake_case_    ,						variant=snake_case_   )   )




			def    lowerCAmelCase__						(							self			:							int   ):
							UpperCamelCase_:				Dict						=    [
							    """safety_checker/pytorch_model.fp16.bin""",
							    """safety_checker/model.fp16.safetensors""",
							    """vae/diffusion_pytorch_model.fp16.bin""",
							    """vae/diffusion_pytorch_model.fp16.safetensors""",
							    """text_encoder/pytorch_model.fp16.bin""",
							    # 'text_encoder/model.fp16.safetensors',
							    """unet/diffusion_pytorch_model.fp16.bin""",
							    """unet/diffusion_pytorch_model.fp16.safetensors""",
							]
							UpperCamelCase_:				Optional[int]						=    """fp16"""
							self.assertFalse(is_safetensors_compatible(snake_case_    ,						variant=snake_case_   )   )








from typing import TYPE_CHECKING

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


lowerCamelCase_    :			Optional[int]    =	{
    """configuration_graphormer""": ["""GRAPHORMER_PRETRAINED_CONFIG_ARCHIVE_MAP""", """GraphormerConfig"""],
}

try:
							if not is_torch_available():
														raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
							pass
else:
							lowerCamelCase_    :			Union[str, Any]    =	[
							    """GRAPHORMER_PRETRAINED_MODEL_ARCHIVE_LIST""",
							    """GraphormerForGraphClassification""",
							    """GraphormerModel""",
							    """GraphormerPreTrainedModel""",
							]


if TYPE_CHECKING:
							from .configuration_graphormer import GRAPHORMER_PRETRAINED_CONFIG_ARCHIVE_MAP, GraphormerConfig

							try:
														if not is_torch_available():
																					raise OptionalDependencyNotAvailable()
							except OptionalDependencyNotAvailable:
														pass
							else:
														from .modeling_graphormer import (
														    GRAPHORMER_PRETRAINED_MODEL_ARCHIVE_LIST,
														    GraphormerForGraphClassification,
														    GraphormerModel,
														    GraphormerPreTrainedModel,
														)


else:
							import sys

							lowerCamelCase_    :			Optional[Any]    =	_LazyModule(__name__, globals()["""__file__"""], _import_structure, module_spec=__spec__)






