lposti commited on
Commit
c635364
1 Parent(s): ffb9b3d

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +22 -2
app.py CHANGED
@@ -25,7 +25,15 @@ def generate_images(prompt: str, negative_prompt:str, num_imgs_to_gen: int, num_
25
  return generated_img
26
 
27
  with gr.Blocks() as demo:
28
- gr.HTML("<h2 style=\"font-size: 2em; font-weight: bold\" align=\"center\"> Dreambooth Galaxy Mergers </h2>")
 
 
 
 
 
 
 
 
29
  with gr.Row():
30
  with gr.Column():
31
  prompt = gr.Textbox(lines=1, value="image of sks galaxies merging in space", label="Base Prompt")
@@ -39,8 +47,20 @@ with gr.Blocks() as demo:
39
 
40
  run.click(generate_images, inputs=[prompt,negative_prompt, samples, num_steps, ugs], outputs=gallery)
41
 
42
- gr.Examples([["image of monument in sks style, 8k, high quality, old paper","colored, deformed, blurry, grain, artifacts, low quality", 1, 30, 18],
 
43
  ],
44
  [prompt,negative_prompt, samples,num_steps, ugs], gallery, generate_images)
45
 
 
 
 
 
 
 
 
 
 
 
 
46
  demo.launch(debug=True)
 
25
  return generated_img
26
 
27
  with gr.Blocks() as demo:
28
+ gr.Markdown(f""""
29
+ # Keras-Dreambooth Galaxy Mergers 🪐🤗
30
+
31
+ This is a Keras Dreambooth model fine-tuned to images of galaxy mergers taken with the [Hubble Space Telescope](https://en.wikipedia.org/wiki/Hubble_Space_Telescope) (credit [ESA/Hubble](https://esahubble.org/images/)).
32
+ The model, part of the [Keras Dreambooth Sprint](https://github.com/huggingface/community-events/tree/main/keras-dreambooth-sprint) trained by lposti, can be found in [keras-dreambooth/dreambooth-galaxy-mergers](https://huggingface.co/keras-dreambooth/dreambooth-galaxy-mergers).
33
+
34
+ The model should be used with a prompt containing `sks galaxies merging`. A typical prompt for this model is `image of sks galaxies merging in space`.
35
+
36
+ """)
37
  with gr.Row():
38
  with gr.Column():
39
  prompt = gr.Textbox(lines=1, value="image of sks galaxies merging in space", label="Base Prompt")
 
47
 
48
  run.click(generate_images, inputs=[prompt,negative_prompt, samples, num_steps, ugs], outputs=gallery)
49
 
50
+ gr.Examples([["image of sks galaxies merging in space, 8k, high quality","deformed, blurry, grain, artifacts, low quality", 1, 40, 12],
51
+ ["painting of sks galaxies merging in van gogh style, 8k, high quality, trending on artstation","deformed, blurry, grain, artifacts, low quality", 1, 40, 12],
52
  ],
53
  [prompt,negative_prompt, samples,num_steps, ugs], gallery, generate_images)
54
 
55
+ gr.Markdown(f""""
56
+ ## Output samples
57
+
58
+ > image of sks galaxies merging in space
59
+ ![image of sks galaxies merging in space, 8k, high quality](https://huggingface.co/keras-dreambooth/dreambooth-galaxy-mergers/resolve/main/output-samples-mergers/db-mergers_collage.jpg)
60
+
61
+ > painting of sks galaxies merging in van gogh style
62
+ ![painting of sks galaxies merging in van gogh style, 8k, high quality, trending on artstation](https://huggingface.co/keras-dreambooth/dreambooth-galaxy-mergers/resolve/main/output-samples-mergers/db-mergers-vangogh_collage.jpg)
63
+
64
+ """)
65
+
66
  demo.launch(debug=True)