Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -42,6 +42,7 @@ if f is not None:
|
|
| 42 |
|
| 43 |
# Check if it's time to capture a frame
|
| 44 |
if frame_count % interval == 0:
|
|
|
|
| 45 |
frame = cv2.resize(frame, (256, 256)) # Resize to (28, 28)
|
| 46 |
frame = np.reshape(frame, (1, 256, 256, 3))
|
| 47 |
st.image(frame, 'input')# Reshape
|
|
|
|
| 42 |
|
| 43 |
# Check if it's time to capture a frame
|
| 44 |
if frame_count % interval == 0:
|
| 45 |
+
frame = cv2.cvtColor(frame, cv2.COLOR_BGR2RGB)
|
| 46 |
frame = cv2.resize(frame, (256, 256)) # Resize to (28, 28)
|
| 47 |
frame = np.reshape(frame, (1, 256, 256, 3))
|
| 48 |
st.image(frame, 'input')# Reshape
|