YiftachEde commited on
Commit
0982ce8
·
1 Parent(s): 3c7a85f
Files changed (2) hide show
  1. app.py +5 -0
  2. requirements.txt +0 -1
app.py CHANGED
@@ -1,4 +1,9 @@
1
  import os
 
 
 
 
 
2
  import torch
3
  import torch.nn as nn
4
  import gradio as gr
 
1
  import os
2
+ # this is a HF Spaces specific hack, as
3
+ # (i) building pytorch3d with GPU support is a bit tricky here
4
+ # (ii) installing the wheel via requirements.txt breaks ZeroGPU
5
+ os.system("pip install pytorch3d -f https://dl.fbaipublicfiles.com/pytorch3d/packaging/wheels/py310_cu121_pyt221/download.html")
6
+
7
  import torch
8
  import torch.nn as nn
9
  import gradio as gr
requirements.txt CHANGED
@@ -21,4 +21,3 @@ rembg
21
  onnxruntime
22
  kiui
23
  --extra-index-url https://download.pytorch.org/whl/cu118
24
- git+https://github.com/facebookresearch/pytorch3d.git@stable
 
21
  onnxruntime
22
  kiui
23
  --extra-index-url https://download.pytorch.org/whl/cu118