


from __future__ import annotations

def 	lowerCAmelCase__			(      a__:		List[Any]      ,  a__:		Any	)  ->		List[str]:


							'''simple docstring'''





							if b == 0:
														return (1, 0)
							(_UpperCAmelCase)					=      extended_euclid(a__      ,  a % b	)
							_UpperCAmelCase					=      a // b
							return (y, x - k * y)

def 	lowerCAmelCase__			(      a__:		List[Any]      ,  a__:		List[Any]      ,  a__:		List[str]      ,  a__:		Any	)  ->		List[str]:


							'''simple docstring'''





							(_UpperCAmelCase)					=      extended_euclid(a__      ,  a__	)
							_UpperCAmelCase					=      na * na
							_UpperCAmelCase					=      ra * x * na + ra * y * na
							return (n % m + m) % m

def 	lowerCAmelCase__			(      a__:		str      ,  a__:		Optional[Any]	)  ->		List[str]:


							'''simple docstring'''





							(_UpperCAmelCase)					=      extended_euclid(a__      ,  a__	)
							if b < 0:
														_UpperCAmelCase					=      (b % n + n) % n
							return b

def 	lowerCAmelCase__			(      a__:		List[Any]      ,  a__:		Tuple      ,  a__:		int      ,  a__:		Dict	)  ->		List[str]:


							'''simple docstring'''





							_UpperCAmelCase					=      invert_modulo(a__      ,  a__	), invert_modulo(a__      ,  a__	)
							_UpperCAmelCase					=      na * na
							_UpperCAmelCase					=      ra * x * na + ra * y * na
							return (n % m + m) % m


if __name__ == "__main__":
		from doctest import testmod

		testmod(name='''chinese_remainder_theorem''', verbose=True)
		testmod(name='''chinese_remainder_theorem2''', verbose=True)
		testmod(name='''invert_modulo''', verbose=True)
		testmod(name='''extended_euclid''', verbose=True)




from dataclasses import dataclass
from typing import List, Optional, Union

import numpy as np
import torch

from ...utils import BaseOutput, OptionalDependencyNotAvailable, is_torch_available, is_transformers_available

@dataclass
class 		__a				(    UpperCAmelCase      ):
		_a     :  Union[List[np.ndarray], torch.FloatTensor]


try:
		if not (is_transformers_available() and is_torch_available()):
				raise OptionalDependencyNotAvailable()
except OptionalDependencyNotAvailable:
		from ...utils.dummy_torch_and_transformers_objects import *  # noqa F403
else:
		from .pipeline_text_to_video_synth import TextToVideoSDPipeline
		from .pipeline_text_to_video_synth_imgaimg import VideoToVideoSDPipeline  # noqa: F401
		from .pipeline_text_to_video_zero import TextToVideoZeroPipeline
