




'''simple docstring'''


def 						SCREAMING_SNAKE_CASE       (      a_	:							dict			):
  __a			=					set()
  # To detect a back edge, keep track of vertices currently in the recursion stack
  __a			=					set()
  return any(
      node not in visited and depth_first_search(a_				,					a_				,					a_				,					a_			)
      for node in graph			)


def 						SCREAMING_SNAKE_CASE       (      a_	:							dict				,					a_	:							int				,					a_	:							set				,					a_	:							set			):
  visited.add(a_			)
  rec_stk.add(a_			)

  for node in graph[vertex]:
    if node not in visited:
      if depth_first_search(a_				,					a_				,					a_				,					a_			):
        return True
    elif node in rec_stk:
      return True

    # The node needs to be removed from recursion stack before function ends
  rec_stk.remove(a_			)
  return False


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

  testmod()









'''simple docstring'''


import torch

from diffusers import StableDiffusionPipeline


UpperCAmelCase_ 		=      "path-to-your-trained-model"
UpperCAmelCase_ 		=      StableDiffusionPipeline.from_pretrained(model_id, torch_dtype=torch.floataa).to("cuda")

UpperCAmelCase_ 		=      "A photo of sks dog in a bucket"
UpperCAmelCase_ 		=      pipe(prompt, num_inference_steps=50, guidance_scale=7.5).images[0]

image.save("dog-bucket.png")



