Update requirements.txt
Browse files- requirements.txt +17 -7
requirements.txt
CHANGED
|
@@ -1,11 +1,21 @@
|
|
| 1 |
-
|
| 2 |
-
|
| 3 |
-
|
| 4 |
|
| 5 |
-
#
|
| 6 |
-
|
| 7 |
-
|
|
|
|
|
|
|
| 8 |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 9 |
gradio==4.44.0
|
| 10 |
opencv-python-headless
|
| 11 |
-
numpy
|
|
|
|
|
|
|
|
|
| 1 |
+
# requirements.txt — CPU attempt for detectron2 (best-effort)
|
| 2 |
+
# NOTE: This pins to a PyTorch/Detectron2 combo that historically has CPU wheels available.
|
| 3 |
+
# If Spaces uses a different python / wheel availability, this may still fail.
|
| 4 |
|
| 5 |
+
# Install PyTorch CPU (explicit) — the -f URL is used by pip to find the +cpu wheels.
|
| 6 |
+
# These exact versions are chosen to match detectron2 wheels historically built for torch1.10.
|
| 7 |
+
torch==1.10.0+cpu
|
| 8 |
+
torchvision==0.11.1+cpu
|
| 9 |
+
-f https://download.pytorch.org/whl/torch_stable.html
|
| 10 |
|
| 11 |
+
# Detectron2 CPU wheel index (find-links). If a matching wheel exists for the above torch,
|
| 12 |
+
# pip will install a prebuilt CPU wheel from this link.
|
| 13 |
+
# If not found, pip will try to build from source (likely to fail on Spaces).
|
| 14 |
+
detectron2==0.6 -f https://dl.fbaipublicfiles.com/detectron2/wheels/cpu/torch1.10/index.html
|
| 15 |
+
|
| 16 |
+
# Common runtime deps for your app
|
| 17 |
gradio==4.44.0
|
| 18 |
opencv-python-headless
|
| 19 |
+
numpy
|
| 20 |
+
Pillow
|
| 21 |
+
protobuf<4
|