OmPrakashSingh1704 commited on
Commit
99c129a
·
1 Parent(s): 4e8bbff
app.py CHANGED
@@ -138,7 +138,7 @@ with gr.Blocks() as demo:
138
  prompt = gr.Textbox(label="Enter the text to get a good start")
139
  btn = gr.Button()
140
  size = gr.Slider(label="Size", minimum=256, maximum=MAX_IMAGE_SIZE, step=8, value=1024)
141
- num_inference_steps = gr.Slider(label="num_inference_steps", minimum=1, maximum=100, value=20)
142
  out_img = gr.Image()
143
  btn.click(Banner.Image2Image_2, [prompt, img,size,num_inference_steps], out_img)
144
 
 
138
  prompt = gr.Textbox(label="Enter the text to get a good start")
139
  btn = gr.Button()
140
  size = gr.Slider(label="Size", minimum=256, maximum=MAX_IMAGE_SIZE, step=8, value=1024)
141
+ num_inference_steps = gr.Slider(label="num_inference_steps", minimum=1, maximum=100,step=1, value=20)
142
  out_img = gr.Image()
143
  btn.click(Banner.Image2Image_2, [prompt, img,size,num_inference_steps], out_img)
144
 
options/Banner_Model/Image2Image_2.py CHANGED
@@ -23,5 +23,5 @@ def I2I_2(image, prompt,size,num_inference_steps):
23
  image.resize((size,size))
24
  image=processor(image)
25
  generator = torch.Generator(device=device).manual_seed(0)
26
- image = pipe(prompt, num_inference_steps=num_inference_steps, generator=generator, image=image,negative_prompt="longbody, lowres, bad anatomy, bad hands, missing fingers, extra digit, fewer digits, cropped, worst quality, low quality").images[0]
27
  return image
 
23
  image.resize((size,size))
24
  image=processor(image)
25
  generator = torch.Generator(device=device).manual_seed(0)
26
+ image = pipe(prompt+"best quality, extremely detailed", num_inference_steps=num_inference_steps, generator=generator, image=image,negative_prompt="longbody, lowres, bad anatomy, bad hands, missing fingers, extra digit, fewer digits, cropped, worst quality, low quality").images[0]
27
  return image
options/Banner_Model/__pycache__/Image2Image_2.cpython-310.pyc CHANGED
Binary files a/options/Banner_Model/__pycache__/Image2Image_2.cpython-310.pyc and b/options/Banner_Model/__pycache__/Image2Image_2.cpython-310.pyc differ
 
options/__pycache__/Banner.cpython-310.pyc CHANGED
Binary files a/options/__pycache__/Banner.cpython-310.pyc and b/options/__pycache__/Banner.cpython-310.pyc differ