Spaces:
Running
Running
Update app.py
#2
by
himmlischerhelmut
- opened
app.py
CHANGED
|
@@ -6,6 +6,14 @@ import sahi.slicing
|
|
| 6 |
from PIL import Image
|
| 7 |
import numpy
|
| 8 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 9 |
IMAGE_SIZE = 640
|
| 10 |
|
| 11 |
# Images
|
|
@@ -140,4 +148,4 @@ gr.Interface(
|
|
| 140 |
examples=examples,
|
| 141 |
theme="huggingface",
|
| 142 |
cache_examples=True,
|
| 143 |
-
).launch(debug=True, enable_queue=True)
|
|
|
|
| 6 |
from PIL import Image
|
| 7 |
import numpy
|
| 8 |
|
| 9 |
+
# MINIMALER FIX - nur diese 3 Zeilen hinzufügen:
|
| 10 |
+
import sys
|
| 11 |
+
import types
|
| 12 |
+
if 'huggingface_hub.utils._errors' not in sys.modules:
|
| 13 |
+
mock_errors = types.ModuleType('_errors')
|
| 14 |
+
mock_errors.RepositoryNotFoundError = Exception
|
| 15 |
+
sys.modules['huggingface_hub.utils._errors'] = mock_errors
|
| 16 |
+
|
| 17 |
IMAGE_SIZE = 640
|
| 18 |
|
| 19 |
# Images
|
|
|
|
| 148 |
examples=examples,
|
| 149 |
theme="huggingface",
|
| 150 |
cache_examples=True,
|
| 151 |
+
).launch(debug=True, enable_queue=True)
|