NikhilJoson commited on
Commit
446b263
1 Parent(s): ced2fa4

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +6 -6
app.py CHANGED
@@ -18,6 +18,7 @@ from diffusers import FluxTransformer2DModel, FluxInpaintPipeline
18
 
19
  MARKDOWN = """
20
  # Prompt Canvas🎨
 
21
  Made using [Flux (Schnell)](https://huggingface.co/black-forest-labs/FLUX.1-schnell), [Grounding-DINO](https://huggingface.co/docs/transformers/main/en/model_doc/grounding-dino) and [SAM](https://huggingface.co/docs/transformers/en/model_doc/sam).
22
  """
23
 
@@ -307,14 +308,14 @@ with gr.Blocks(theme=gr.themes.Ocean()) as demo:
307
  strength_slider = gr.Slider(
308
  minimum=0.0,
309
  maximum=1.0,
310
- value=0.9,
311
  step=0.01,
312
  label="Strength"
313
  )
314
  num_inference_steps = gr.Slider(
315
  minimum=1,
316
  maximum=100,
317
- value=32,
318
  step=1,
319
  label="Number of inference steps"
320
  )
@@ -341,7 +342,7 @@ with gr.Blocks(theme=gr.themes.Ocean()) as demo:
341
  )
342
  expansion_level = gr.Slider(
343
  minimum=0,
344
- maximum=20,
345
  value=2,
346
  step=1,
347
  label="Mask Expansion level"
@@ -350,11 +351,10 @@ with gr.Blocks(theme=gr.themes.Ocean()) as demo:
350
  minimum=0,
351
  maximum=5,
352
  step=1,
353
- value=1,
354
  label="Mask Blur level"
355
  )
356
- # with gr.Accordion("Upload a mask", open=False):
357
- # uploaded_mask_component = gr.Image(label="Already made mask (black pixels will be preserved, white pixels will be redrawn)", sources=["upload"], type="pil")
358
  submit_button_component = gr.Button(value='Inpaint', variant='primary')
359
  with gr.Column(scale=1):
360
  output_image_component = gr.Image(type='pil', image_mode='RGB', label='Generated Image')
 
18
 
19
  MARKDOWN = """
20
  # Prompt Canvas🎨
21
+ Modify any image by using a single Prompt and an Image.
22
  Made using [Flux (Schnell)](https://huggingface.co/black-forest-labs/FLUX.1-schnell), [Grounding-DINO](https://huggingface.co/docs/transformers/main/en/model_doc/grounding-dino) and [SAM](https://huggingface.co/docs/transformers/en/model_doc/sam).
23
  """
24
 
 
308
  strength_slider = gr.Slider(
309
  minimum=0.0,
310
  maximum=1.0,
311
+ value=0.96,
312
  step=0.01,
313
  label="Strength"
314
  )
315
  num_inference_steps = gr.Slider(
316
  minimum=1,
317
  maximum=100,
318
+ value=16,
319
  step=1,
320
  label="Number of inference steps"
321
  )
 
342
  )
343
  expansion_level = gr.Slider(
344
  minimum=0,
345
+ maximum=10,
346
  value=2,
347
  step=1,
348
  label="Mask Expansion level"
 
351
  minimum=0,
352
  maximum=5,
353
  step=1,
354
+ value=0,
355
  label="Mask Blur level"
356
  )
357
+
 
358
  submit_button_component = gr.Button(value='Inpaint', variant='primary')
359
  with gr.Column(scale=1):
360
  output_image_component = gr.Image(type='pil', image_mode='RGB', label='Generated Image')