Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
|
@@ -37,7 +37,7 @@ def preprocess_image(image, device):
|
|
| 37 |
# Convert cropped face back to PIL for further processing
|
| 38 |
processed_image = Image.fromarray(cv2.cvtColor(cropped_face, cv2.COLOR_BGR2RGB))
|
| 39 |
else:
|
| 40 |
-
st.
|
| 41 |
processed_image = image # Use the original image if no face is detected
|
| 42 |
|
| 43 |
# Transform image for model
|
|
|
|
| 37 |
# Convert cropped face back to PIL for further processing
|
| 38 |
processed_image = Image.fromarray(cv2.cvtColor(cropped_face, cv2.COLOR_BGR2RGB))
|
| 39 |
else:
|
| 40 |
+
st.warning("No face Detected/Low Quality Image , Results can be Inaccurate")
|
| 41 |
processed_image = image # Use the original image if no face is detected
|
| 42 |
|
| 43 |
# Transform image for model
|