Spaces:
Running on Zero
Running on Zero
Upload app.py with huggingface_hub
Browse files
app.py
CHANGED
|
@@ -94,7 +94,7 @@ def _frames_to_video_tensor(frame_list):
|
|
| 94 |
def _to_data_uri(frame01):
|
| 95 |
im = Image.fromarray((np.clip(frame01, 0, 1) * 255.0).astype(np.uint8))
|
| 96 |
buf = BytesIO()
|
| 97 |
-
im.save(buf, format="JPEG", quality=
|
| 98 |
return "data:image/jpeg;base64," + base64.b64encode(buf.getvalue()).decode()
|
| 99 |
|
| 100 |
|
|
|
|
| 94 |
def _to_data_uri(frame01):
|
| 95 |
im = Image.fromarray((np.clip(frame01, 0, 1) * 255.0).astype(np.uint8))
|
| 96 |
buf = BytesIO()
|
| 97 |
+
im.save(buf, format="JPEG", quality=70)
|
| 98 |
return "data:image/jpeg;base64," + base64.b64encode(buf.getvalue()).decode()
|
| 99 |
|
| 100 |
|