fix: install vendored detectron2 in postBuild (HF build order)
Browse files- packages.txt +1 -0
- postBuild +7 -0
- requirements.txt +3 -2
packages.txt
CHANGED
|
@@ -1,3 +1,4 @@
|
|
| 1 |
build-essential
|
| 2 |
python3-dev
|
|
|
|
| 3 |
|
|
|
|
| 1 |
build-essential
|
| 2 |
python3-dev
|
| 3 |
+
ninja-build
|
| 4 |
|
postBuild
ADDED
|
@@ -0,0 +1,7 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
#!/bin/sh
|
| 2 |
+
set -e
|
| 3 |
+
|
| 4 |
+
echo "[postBuild] Installing vendored detectron2 from MaskClustering/third_party/detectron2 ..."
|
| 5 |
+
pip install --no-cache-dir -e MaskClustering/third_party/detectron2
|
| 6 |
+
|
| 7 |
+
|
requirements.txt
CHANGED
|
@@ -20,5 +20,6 @@ scipy
|
|
| 20 |
onnxruntime
|
| 21 |
gdown
|
| 22 |
|
| 23 |
-
#
|
| 24 |
-
|
|
|
|
|
|
| 20 |
onnxruntime
|
| 21 |
gdown
|
| 22 |
|
| 23 |
+
# NOTE (HF Spaces): do not use local-path installs here.
|
| 24 |
+
# HF builds install requirements BEFORE copying the repo into /app.
|
| 25 |
+
# detectron2 is installed from vendored source in `postBuild`.
|