Spaces:
Paused
Paused
Update app.py
Browse files
app.py
CHANGED
|
@@ -61,7 +61,8 @@ def process_images(files):
|
|
| 61 |
# --optim_pose \
|
| 62 |
|
| 63 |
scene = hashdir_name
|
| 64 |
-
|
|
|
|
| 65 |
|
| 66 |
command = [
|
| 67 |
"python", "-W", "ignore",
|
|
@@ -108,9 +109,9 @@ def process_images(files):
|
|
| 108 |
stderr = '\n'.join(stderr)
|
| 109 |
|
| 110 |
result_tree = subprocess.run(["tree", hashdir_path], capture_output=True, text=True)
|
| 111 |
-
ply_file = os.path.join(
|
| 112 |
|
| 113 |
-
return result_tree.stdout, stdout, stderr
|
| 114 |
|
| 115 |
def run():
|
| 116 |
with gr.Blocks() as demo:
|
|
@@ -121,7 +122,7 @@ def run():
|
|
| 121 |
# outputs = [gr.Image(type="numpy", label="Processed Images", interactive=False), gr.Video(label="Output Video")]
|
| 122 |
# outputs = [gr.Textbox(label="Log"), gr.Image(type="filepath", label="Processed Images", interactive=False)]
|
| 123 |
outputs = [
|
| 124 |
-
|
| 125 |
gr.Textbox(label="Output dirs"),
|
| 126 |
gr.Textbox(label="Log (stdout)"),
|
| 127 |
gr.Textbox(label="Log (stderr)"),
|
|
|
|
| 61 |
# --optim_pose \
|
| 62 |
|
| 63 |
scene = hashdir_name
|
| 64 |
+
subdir = f'{n_view}_views_{gs_train_iter}Iter_{pose_lr}PoseLR'
|
| 65 |
+
model_path = os.path.join(hashdir_path, 'infer', scene, subdir)
|
| 66 |
|
| 67 |
command = [
|
| 68 |
"python", "-W", "ignore",
|
|
|
|
| 109 |
stderr = '\n'.join(stderr)
|
| 110 |
|
| 111 |
result_tree = subprocess.run(["tree", hashdir_path], capture_output=True, text=True)
|
| 112 |
+
ply_file = os.path.join(model_path, 'point_cloud', f'iteration_{gs_train_iter}', 'point_cloud.ply')
|
| 113 |
|
| 114 |
+
return ply_file, result_tree.stdout, stdout, stderr
|
| 115 |
|
| 116 |
def run():
|
| 117 |
with gr.Blocks() as demo:
|
|
|
|
| 122 |
# outputs = [gr.Image(type="numpy", label="Processed Images", interactive=False), gr.Video(label="Output Video")]
|
| 123 |
# outputs = [gr.Textbox(label="Log"), gr.Image(type="filepath", label="Processed Images", interactive=False)]
|
| 124 |
outputs = [
|
| 125 |
+
gr.Model3D(label="3D Model"),
|
| 126 |
gr.Textbox(label="Output dirs"),
|
| 127 |
gr.Textbox(label="Log (stdout)"),
|
| 128 |
gr.Textbox(label="Log (stderr)"),
|