Spaces:
Runtime error
Runtime error
fix
Browse filesFiles changed (2)
- Dockerfile+12-7
- app.py-1
3 unmodified lines456789101112131415161718192021222324252627282930315 unmodified lines3738393 unmodified linesENV DEBIAN_FRONTEND=noninteractive \PIP_NO_CACHE_DIR=1# Minimal runtime depsRUN apt-get update && apt-get install -y --no-install-recommends \python3 python3-pip git wget ca-certificates libgl1 \&& rm -rf /var/lib/apt/lists/*# Pip tooling compatible with this older stackRUN python3 -m pip install --upgrade pip setuptools==59.5.0 wheel# Pillow pin avoids Detectron2 0.6 breakages with Pillow 10+RUN python3 -m pip install --no-cache-dir "pillow==9.5.0"# Core ML stack (CUDA 11.1 wheels)RUN python3 -m pip install --no-cache-dir \--extra-index-url https://download.pytorch.org/whl/cu111 \torch==1.10.0+cu111 torchvision==0.11.1+cu111# Detectron2 0.6 prebuilt for torch1.10/cu111RUN python3 -m pip install --no-cache-dir -f \https://dl.fbaipublicfiles.com/detectron2/wheels/cu111/torch1.10/index.html \detectron2==0.6# Geospatial + UI + detectree2RUN python3 -m pip install --no-cache-dir \gradio==4.* rasterio geopandas shapely matplotlib \"git+https://github.com/PatBall1/detectree2.git"5 unmodified linesCOPY weights /weightsCMD ["python3", "app.py"]3 unmodified lines456789101112131415161718192021222324252627282930313233345 unmodified lines40414243443 unmodified linesENV DEBIAN_FRONTEND=noninteractive \PIP_NO_CACHE_DIR=1# Minimal runtime deps (+ glib for cv2)RUN apt-get update && apt-get install -y --no-install-recommends \python3 python3-pip git wget ca-certificates libglib2.0-0 \&& rm -rf /var/lib/apt/lists/*# Pip toolingRUN python3 -m pip install --upgrade pip setuptools==59.5.0 wheel# Force headless OpenCV (no libGL/gtk needed)RUN python3 -m pip install --no-cache-dir "opencv-python-headless==4.8.1.78" && \python3 -m pip uninstall -y opencv-python opencv-contrib-python || true# Pillow pinRUN python3 -m pip install --no-cache-dir "pillow==9.5.0"# Torch/cu111 + detectron2 0.6RUN python3 -m pip install --no-cache-dir \--extra-index-url https://download.pytorch.org/whl/cu111 \torch==1.10.0+cu111 torchvision==0.11.1+cu111RUN python3 -m pip install --no-cache-dir -f \https://dl.fbaipublicfiles.com/detectron2/wheels/cu111/torch1.10/index.html \detectron2==0.6# Geo + UI + detectree2RUN python3 -m pip install --no-cache-dir \gradio==4.* rasterio geopandas shapely matplotlib \"git+https://github.com/PatBall1/detectree2.git"5 unmodified linesCOPY weights /weightsCMD ["python3", "app.py"]
46 unmodified lines4748495051525346 unmodified lines# --------- Config ---------WEIGHTS = {# NOTE: Dockerfile downloads this to /weights"Forest": "/weights/230103_randresize_full.pth",# "Urban": "/weights/urban_trees_Cambridge_20230630.pth",# "Flexi": "/weights/250312_flexi.pth",46 unmodified lines47484950515246 unmodified lines# --------- Config ---------WEIGHTS = {"Forest": "/weights/230103_randresize_full.pth",# "Urban": "/weights/urban_trees_Cambridge_20230630.pth",# "Flexi": "/weights/250312_flexi.pth",
Dockerfile+12-7
app.py-1