





import unittest

from transformers import load_tool
from transformers.utils import is_torch_available


if is_torch_available():
    import torch

from transformers.testing_utils import require_torch

from .test_tools_common import ToolTesterMixin





@require_torch
class  A__    (							unittest.TestCase ,  __UpperCAmelCase	):




   """simple docstring"""



   def 							__lowercase		(					self)			->						Any:







          '''simple docstring'''

          a__						:	List[str] =				load_tool('text-to-speech')
          self.tool.setup()

   def 							__lowercase		(					self)			->						int:







          '''simple docstring'''

          torch.manual_seed(0)
          a__						:	Any =				self.tool('hey')
          a__						:	Dict =				result.to_raw()
          self.assertTrue(
              torch.allclose(
                  resulting_tensor[:3]					,  torch.tensor([-0.0_00_59_66_66_88_32_11_58_29, -0.0_00_36_57_64_01_90_79_50_64, -0.00_01_34_39_50_27_99_88_34_85])					,  ))

   def 							__lowercase		(					self)			->						Union[str, Any]:







          '''simple docstring'''

          torch.manual_seed(0)
          a__						:	List[str] =				self.tool('hey')
          a__						:	Tuple =				result.to_raw()
          self.assertTrue(
              torch.allclose(
                  resulting_tensor[:3]					,  torch.tensor([-0.0_00_59_66_66_88_32_11_58_29, -0.0_00_36_57_64_01_90_79_50_64, -0.00_01_34_39_50_27_99_88_34_85])					,  ))









from ..utils import is_flax_available, is_torch_available


if is_torch_available():
    from .autoencoder_kl import AutoencoderKL
    from .controlnet import ControlNetModel
    from .dual_transformer_ad import DualTransformeraDModel
    from .modeling_utils import ModelMixin
    from .prior_transformer import PriorTransformer
    from .ta_film_transformer import TaFilmDecoder
    from .transformer_ad import TransformeraDModel
    from .unet_ad import UNetaDModel
    from .unet_ad import UNetaDModel
    from .unet_ad_condition import UNetaDConditionModel
    from .unet_ad_condition import UNetaDConditionModel
    from .vq_model import VQModel

if is_flax_available():
    from .controlnet_flax import FlaxControlNetModel
    from .unet_ad_condition_flax import FlaxUNetaDConditionModel
    from .vae_flax import FlaxAutoencoderKL


