cezar-hapiko commited on
Commit
e385936
·
1 Parent(s): da25273

Ship pre-built CUDA wheels (TE+TE_torch/VIPE/DA3/gsplat) via Git LFS

Browse files
.gitattributes ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ # Pre-built CUDA-extension wheels (built on Modal, shipped via Git LFS).
2
+ # They're >10 MB each and can't be compiled on HF's memory-constrained builder.
3
+ wheels/*.whl filter=lfs diff=lfs merge=lfs -text
Dockerfile CHANGED
@@ -85,34 +85,26 @@ RUN sed -i 's/^tensorstore==0\.1\.45/tensorstore==0.1.50/' Lyra-2/requirements.t
85
  RUN uv pip install -r Lyra-2/requirements.txt && \
86
  uv pip install "git+https://github.com/microsoft/MoGe.git"
87
 
88
- # Build backends some extensions expect on PYTHONPATH even with --no-build-isolation.
89
  RUN uv pip install setuptools wheel ninja
90
 
91
- # --- CUDA extensions (all need --no-build-isolation + CPATH) ---------------
92
- RUN source /home/user/.buildrc && \
93
- uv pip install --no-build-isolation "transformer_engine[pytorch]"
 
 
 
94
 
95
- # flash-attn: prebuilt wheel for torch 2.7 / cu12 / py312.
96
  RUN uv pip install \
97
  "https://github.com/Dao-AILab/flash-attention/releases/download/v2.7.4.post1/flash_attn-2.7.4.post1+cu12torch2.7cxx11abiFALSE-cp312-cp312-linux_x86_64.whl"
98
 
99
- RUN source /home/user/.buildrc && \
100
- uv pip install --no-build-isolation -e Lyra-2/lyra_2/_src/inference/vipe
101
-
102
- RUN source /home/user/.buildrc && \
103
- uv pip install --no-build-isolation -e "Lyra-2/lyra_2/_src/inference/depth_anything_3[gs]"
104
-
105
- # DA3's undeclared transitive runtime deps (addict is missing from its
106
- # pyproject.toml; --no-build-isolation skips the rest of the resolver).
107
  RUN uv pip install \
108
  addict evo e3nn plyfile pillow-heif moviepy open3d typer \
109
  kornia pycolmap trimesh fastapi uvicorn gradio
110
 
111
- # gsplat at DA3's pinned commit (different from Lyra-1's gsplat commit).
112
- RUN source /home/user/.buildrc && \
113
- uv pip install --no-build-isolation \
114
- "git+https://github.com/nerfstudio-project/gsplat.git@0b4dddf04cb687367602c01196913cde6a743d70"
115
-
116
  # Repin huggingface_hub < 1.0 (chain installs can bump past 1.0 and break
117
  # transformers) and gdown < 6 (6.0 removed the `fuzzy` kwarg VIPE uses).
118
  RUN uv pip install "huggingface_hub>=0.36.0,<1.0" "gdown<6"
 
85
  RUN uv pip install -r Lyra-2/requirements.txt && \
86
  uv pip install "git+https://github.com/microsoft/MoGe.git"
87
 
88
+ # Build backend metadata (needed for wheel install of editables and as a safety net).
89
  RUN uv pip install setuptools wheel ninja
90
 
91
+ # --- CUDA extensions: install from pre-built wheels via Git LFS ------------
92
+ # HF Space builders can't compile TE/VIPE/DA3/gsplat (OOMs silently after 10+ min).
93
+ # Wheels in ./wheels/ are compiled once on Modal (1.9 TB RAM) and shipped via Git LFS.
94
+ # They're ABI-pinned to Python 3.12 + torch 2.7.1+cu128 which is what this image has.
95
+ COPY --chown=user wheels/ ./wheels/
96
+ RUN uv pip install ./wheels/*.whl
97
 
98
+ # flash-attn: upstream prebuilt wheel for torch 2.7 / cu12 / py312.
99
  RUN uv pip install \
100
  "https://github.com/Dao-AILab/flash-attention/releases/download/v2.7.4.post1/flash_attn-2.7.4.post1+cu12torch2.7cxx11abiFALSE-cp312-cp312-linux_x86_64.whl"
101
 
102
+ # DA3's undeclared transitive runtime deps (addict missing from its pyproject;
103
+ # these aren't resolved when we install from local wheels with pre-compiled .so).
 
 
 
 
 
 
104
  RUN uv pip install \
105
  addict evo e3nn plyfile pillow-heif moviepy open3d typer \
106
  kornia pycolmap trimesh fastapi uvicorn gradio
107
 
 
 
 
 
 
108
  # Repin huggingface_hub < 1.0 (chain installs can bump past 1.0 and break
109
  # transformers) and gdown < 6 (6.0 removed the `fuzzy` kwarg VIPE uses).
110
  RUN uv pip install "huggingface_hub>=0.36.0,<1.0" "gdown<6"
wheels/depth_anything_3-0.0.0-py3-none-any.whl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:ebc7673e06ebca579b1c6aff0020efaaa36af4694dc6a98102879a3a1c83798d
3
+ size 275590
wheels/gsplat-1.5.2-cp312-cp312-linux_x86_64.whl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:9757c825b478a4d3e27d233cf1980544ee141e81784abbc856288c2e2d70964f
3
+ size 9526016
wheels/transformer_engine-2.13.0-py3-none-any.whl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:cb1ad42df836dbe704f9bd140089d6358d7ebea2eeb36f90d533af4504fe2005
3
+ size 769798
wheels/transformer_engine_torch-2.13.0-cp312-cp312-linux_x86_64.whl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:314e500655f11ba6bde091229159de372adbf580e8d93b21c57e50d2329f0831
3
+ size 714891
wheels/vipe-0.1.1+pt27cu128-cp312-cp312-linux_x86_64.whl ADDED
@@ -0,0 +1,3 @@
 
 
 
 
1
+ version https://git-lfs.github.com/spec/v1
2
+ oid sha256:a28087896bb743aadb95edc4fb6c5e3f64dac817c902b40e2c815eb62d88759a
3
+ size 1855161