more fixes
Browse files
app.py
CHANGED
@@ -206,13 +206,7 @@ def predict_image(img, confidence_threshold):
|
|
206 |
except Exception as e:
|
207 |
label_5 = f"Error: {str(e)}"
|
208 |
|
209 |
-
|
210 |
-
augmented_img_flip, augmented_img_rotate = augment_image(img_pil)
|
211 |
-
|
212 |
-
# Convert augmented images to bytes for display
|
213 |
-
augmented_img_flip_bytes = convert_pil_to_bytes(augmented_img_flip)
|
214 |
-
augmented_img_rotate_bytes = convert_pil_to_bytes(augmented_img_rotate)
|
215 |
-
|
216 |
# Combine results
|
217 |
combined_results = {
|
218 |
"SwinV2/detect": label_1,
|
@@ -224,9 +218,9 @@ def predict_image(img, confidence_threshold):
|
|
224 |
# Generate HTML content
|
225 |
|
226 |
combined_outputs = [ result_1output, result_2output, result_3output, result_4output, result_5output ]
|
227 |
-
html_content = generate_results_html(combined_outputs)
|
228 |
|
229 |
-
return img_pil, combined_outputs
|
230 |
|
231 |
# Define a function to generate the HTML content
|
232 |
# Define a function to generate the HTML content
|
|
|
206 |
except Exception as e:
|
207 |
label_5 = f"Error: {str(e)}"
|
208 |
|
209 |
+
|
|
|
|
|
|
|
|
|
|
|
|
|
210 |
# Combine results
|
211 |
combined_results = {
|
212 |
"SwinV2/detect": label_1,
|
|
|
218 |
# Generate HTML content
|
219 |
|
220 |
combined_outputs = [ result_1output, result_2output, result_3output, result_4output, result_5output ]
|
221 |
+
# html_content = generate_results_html(combined_outputs)
|
222 |
|
223 |
+
return img_pil, combined_outputs
|
224 |
|
225 |
# Define a function to generate the HTML content
|
226 |
# Define a function to generate the HTML content
|