
'''simple docstring'''





class     a :




				def __init__(				self						:					Dict   ):
										snake_case							:  List[str]			=     []
										snake_case							:  Any			=     0
										snake_case							:  Union[str, Any]			=     0




				def __str__(				self						:					Dict   ):
										snake_case							:  Optional[Any]			=     '''<''' + str(self.entries   )[1:-1] + '''>'''
										return printed




				def 						__snake_case				(				self						:					Optional[int],     SCREAMING_SNAKE_CASE_						:					Union[str, Any]   ):
										self.entries.append(SCREAMING_SNAKE_CASE_   )
										snake_case							:  int			=     self.length + 1




				def 						__snake_case				(				self						:					Dict   ):
										snake_case							:  Tuple			=     self.length - 1
										snake_case							:  Optional[int]			=     self.entries[self.front]
										# self.front-=1
										# self.entries = self.entries[self.front:]
										snake_case							:  List[Any]			=     self.entries[1:]
										return dequeued




				def 						__snake_case				(				self						:					Tuple,     SCREAMING_SNAKE_CASE_						:					Dict   ):
										for _ in range(SCREAMING_SNAKE_CASE_   ):
																self.put(self.get()   )




				def 						__snake_case				(				self						:					List[str]   ):
										return self.entries[0]




				def 						__snake_case				(				self						:					int   ):
										return self.length



import unittest

import torch

from diffusers import DDIMScheduler, TextToVideoZeroPipeline
from diffusers.utils import load_pt, require_torch_gpu, slow

from ..test_pipelines_common import assert_mean_pixel_difference







@slow
@require_torch_gpu
class 							lowercase						(   unittest.TestCase						):




							def 					A__ (							self):
												lowercase		      =		'''runwayml/stable-diffusion-v1-5'''
												lowercase		      =		TextToVideoZeroPipeline.from_pretrained(A__  ,torch_dtype=torch.floataa).to('''cuda''')
												lowercase		      =		DDIMScheduler.from_config(pipe.scheduler.config)
												lowercase		      =		torch.Generator(device='''cuda''').manual_seed(0)

												lowercase		      =		'''A bear is playing a guitar on Times Square'''
												lowercase		      =		pipe(prompt=A__  ,generator=A__).images

												lowercase		      =		load_pt(
												    '''https://huggingface.co/datasets/hf-internal-testing/diffusers-images/resolve/main/text-to-video/A bear is playing a guitar on Times Square.pt''')

												assert_mean_pixel_difference(A__  ,A__)




