Spaces:
Sleeping
Sleeping
Update app.py
Browse files12 unmodified lines131415161718194 unmodified lines2425262728293012 unmodified linesgray_image = cv2.cvtColor(img, cv2.COLOR_RGB2GRAY)# Detect facesfaces = face_cascade.detectMultiScale(gray_image, scaleFactor=]slider, minNeighbors=5, minSize=(30, 30))# Draw rectangles around facesfor (x, y, w, h) in faces:4 unmodified lines# Create Gradio Interfaceiface = gr.Interface(fn=detect_faces,inputs=["image","slider"]outputs="image",title="Face Detection",description="Upload an image, and the model will detect faces and draw bounding boxes around them."12 unmodified lines131415161718194 unmodified lines2425262728293012 unmodified linesgray_image = cv2.cvtColor(img, cv2.COLOR_RGB2GRAY)# Detect facesfaces = face_cascade.detectMultiScale(gray_image, scaleFactor=slider, minNeighbors=5, minSize=(30, 30))# Draw rectangles around facesfor (x, y, w, h) in faces:4 unmodified lines# Create Gradio Interfaceiface = gr.Interface(fn=detect_faces,inputs=["image","slider"],outputs="image",title="Face Detection",description="Upload an image, and the model will detect faces and draw bounding boxes around them."
app.py+2-2