Spaces:
Running
on
L40S
Running
on
L40S
Update app.py
Browse files
app.py
CHANGED
@@ -105,7 +105,10 @@ def generate_image(setup_args, num_iterations):
|
|
105 |
|
106 |
# Define progress_callback that updates steps_completed
|
107 |
def progress_callback(step):
|
108 |
-
|
|
|
|
|
|
|
109 |
|
110 |
# Function to run main in a separate thread
|
111 |
def run_main():
|
|
|
105 |
|
106 |
# Define progress_callback that updates steps_completed
|
107 |
def progress_callback(step):
|
108 |
+
# Limit redundant prints by checking the step number
|
109 |
+
if not steps_completed or step > steps_completed[-1]:
|
110 |
+
steps_completed.append(step)
|
111 |
+
print(f"Progress: Step {step} completed.")
|
112 |
|
113 |
# Function to run main in a separate thread
|
114 |
def run_main():
|