Spaces:
Sleeping
Sleeping
Srimanth Agastyaraju
commited on
Commit
·
3827896
1
Parent(s):
c4737c4
Increase num_steps in inference pipeline to 9, bug fix
Browse files- .ipynb_checkpoints/app-checkpoint.py +3 -3
- app.py +3 -3
.ipynb_checkpoints/app-checkpoint.py
CHANGED
@@ -24,7 +24,7 @@ def inference(prompt, model, n_images, seed):
|
|
24 |
print(f"Inferencing '{prompt}' for {n_images} images.")
|
25 |
|
26 |
for i in range(n_images):
|
27 |
-
result = pipe(prompt, generator=generators[i], num_inference_steps=
|
28 |
result_images.append(result)
|
29 |
|
30 |
# Start with empty UI elements
|
@@ -33,8 +33,8 @@ def inference(prompt, model, n_images, seed):
|
|
33 |
|
34 |
# Update the progress bar
|
35 |
with progress_bar_ui.container():
|
36 |
-
value = ((i+1)/
|
37 |
-
progress_bar.progress(value, text=f"{i+1} out of {
|
38 |
|
39 |
# Update the image grid
|
40 |
with image_grid_ui.container():
|
|
|
24 |
print(f"Inferencing '{prompt}' for {n_images} images.")
|
25 |
|
26 |
for i in range(n_images):
|
27 |
+
result = pipe(prompt, generator=generators[i], num_inference_steps=9).images[0]
|
28 |
result_images.append(result)
|
29 |
|
30 |
# Start with empty UI elements
|
|
|
33 |
|
34 |
# Update the progress bar
|
35 |
with progress_bar_ui.container():
|
36 |
+
value = ((i+1)/n_images)
|
37 |
+
progress_bar.progress(value, text=f"{i+1} out of {n_images} images processed.")
|
38 |
|
39 |
# Update the image grid
|
40 |
with image_grid_ui.container():
|
app.py
CHANGED
@@ -24,7 +24,7 @@ def inference(prompt, model, n_images, seed):
|
|
24 |
print(f"Inferencing '{prompt}' for {n_images} images.")
|
25 |
|
26 |
for i in range(n_images):
|
27 |
-
result = pipe(prompt, generator=generators[i], num_inference_steps=
|
28 |
result_images.append(result)
|
29 |
|
30 |
# Start with empty UI elements
|
@@ -33,8 +33,8 @@ def inference(prompt, model, n_images, seed):
|
|
33 |
|
34 |
# Update the progress bar
|
35 |
with progress_bar_ui.container():
|
36 |
-
value = ((i+1)/
|
37 |
-
progress_bar.progress(value, text=f"{i+1} out of {
|
38 |
|
39 |
# Update the image grid
|
40 |
with image_grid_ui.container():
|
|
|
24 |
print(f"Inferencing '{prompt}' for {n_images} images.")
|
25 |
|
26 |
for i in range(n_images):
|
27 |
+
result = pipe(prompt, generator=generators[i], num_inference_steps=9).images[0]
|
28 |
result_images.append(result)
|
29 |
|
30 |
# Start with empty UI elements
|
|
|
33 |
|
34 |
# Update the progress bar
|
35 |
with progress_bar_ui.container():
|
36 |
+
value = ((i+1)/n_images)
|
37 |
+
progress_bar.progress(value, text=f"{i+1} out of {n_images} images processed.")
|
38 |
|
39 |
# Update the image grid
|
40 |
with image_grid_ui.container():
|