Eeman Majumder commited on
Commit
1b54286
·
1 Parent(s): 9b2b04c
Files changed (1) hide show
  1. app.py +5 -4
app.py CHANGED
@@ -21,13 +21,13 @@ prompt=st.text_input('Enter Your Prompt')
21
 
22
  model_id = "CompVis/stable-diffusion-v1-4"
23
  device = "cpu"
24
-
25
  #___________________________________________________________________________________________________________________________
26
 
27
  pipe = StableDiffusionPipeline.from_pretrained(model_id, use_auth_token='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', torch_dtype=torch.float32)
28
  def dummy(images, **kwargs): return images, False
29
  pipe.safety_checker = dummy
30
-
31
  #___________________________________________________________________________________________________________________________
32
 
33
  def infer(prompt, width, height, steps, scale, seed):
@@ -48,14 +48,15 @@ def infer(prompt, width, height, steps, scale, seed):
48
  guidance_scale=scale)
49
 
50
  return images_list["sample"]
51
-
 
52
  #___________________________________________________________________________________________________________________________
53
 
54
  def onclick(prompt):
55
  st.image(infer(prompt,512,512,30,7.5,-1))
56
-
57
  if prompt==True:
58
  onclick(prompt)
 
59
 
60
  #___________________________________________________________________________________________________________________________
61
 
 
21
 
22
  model_id = "CompVis/stable-diffusion-v1-4"
23
  device = "cpu"
24
+ st.info('1')
25
  #___________________________________________________________________________________________________________________________
26
 
27
  pipe = StableDiffusionPipeline.from_pretrained(model_id, use_auth_token='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', torch_dtype=torch.float32)
28
  def dummy(images, **kwargs): return images, False
29
  pipe.safety_checker = dummy
30
+ st.info(2)
31
  #___________________________________________________________________________________________________________________________
32
 
33
  def infer(prompt, width, height, steps, scale, seed):
 
48
  guidance_scale=scale)
49
 
50
  return images_list["sample"]
51
+ st.info(5)
52
+ st.info(3)
53
  #___________________________________________________________________________________________________________________________
54
 
55
  def onclick(prompt):
56
  st.image(infer(prompt,512,512,30,7.5,-1))
 
57
  if prompt==True:
58
  onclick(prompt)
59
+ st.info(4)
60
 
61
  #___________________________________________________________________________________________________________________________
62