Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -20,8 +20,8 @@ def detect_faces(image , slider ) :
|
|
| 20 |
cv2.rectangle(image_np, (x, y), (x+w, y+h), (255, 0, 0), 5)
|
| 21 |
return image_np
|
| 22 |
|
| 23 |
-
slider = gr.Slider(1, 2, step=.1, label="Adjust the ScaleFactor", value=1.5)
|
| 24 |
|
| 25 |
-
iface = gr.Interface( fn=detect_faces,inputs=["image","slider"],outputs="image",title="Face Detection using Haar Cascade Classifier ",description="Upload an image,and the model will detect faces and draw bounding boxes around them.",)
|
| 26 |
|
| 27 |
iface.launch()
|
|
|
|
| 20 |
cv2.rectangle(image_np, (x, y), (x+w, y+h), (255, 0, 0), 5)
|
| 21 |
return image_np
|
| 22 |
|
| 23 |
+
# slider = gr.Slider(1, 2, step=.1, label="Adjust the ScaleFactor", value=1.5)
|
| 24 |
|
| 25 |
+
iface = gr.Interface( fn=detect_faces,inputs=["image","slider"],outputs="image",gr.Slider(1, 2, step=.1, label="Adjust the ScaleFactor", value=1.5),title="Face Detection using Haar Cascade Classifier ",description="Upload an image,and the model will detect faces and draw bounding boxes around them.",)
|
| 26 |
|
| 27 |
iface.launch()
|