Spaces:
Running
on
Zero
Running
on
Zero
Stanislaw Szymanowicz
commited on
Commit
•
de8d36c
1
Parent(s):
21506fa
Install rasterizer at runtime
Browse files- gaussian_renderer/__init__.py +7 -1
- requirements.txt +1 -2
gaussian_renderer/__init__.py
CHANGED
@@ -4,8 +4,14 @@
|
|
4 |
import math
|
5 |
import torch
|
6 |
import numpy as np
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
7 |
|
8 |
-
from diff_gaussian_rasterization import GaussianRasterizationSettings, GaussianRasterizer
|
9 |
from utils.graphics_utils import focal2fov
|
10 |
|
11 |
def render_predicted(pc : dict,
|
|
|
4 |
import math
|
5 |
import torch
|
6 |
import numpy as np
|
7 |
+
import os
|
8 |
+
|
9 |
+
try:
|
10 |
+
from diff_gaussian_rasterization import GaussianRasterizationSettings, GaussianRasterizer
|
11 |
+
except ImportError:
|
12 |
+
os.system("pip install git+https://github.com/graphdeco-inria/diff-gaussian-rasterization")
|
13 |
+
from diff_gaussian_rasterization import GaussianRasterizationSettings, GaussianRasterizer
|
14 |
|
|
|
15 |
from utils.graphics_utils import focal2fov
|
16 |
|
17 |
def render_predicted(pc : dict,
|
requirements.txt
CHANGED
@@ -8,5 +8,4 @@ moviepy
|
|
8 |
markupsafe==2.0.1
|
9 |
gradio==4.25.0
|
10 |
rembg
|
11 |
-
spaces
|
12 |
-
git+https://github.com/graphdeco-inria/diff-gaussian-rasterization
|
|
|
8 |
markupsafe==2.0.1
|
9 |
gradio==4.25.0
|
10 |
rembg
|
11 |
+
spaces
|
|