--export_uv_textured_mesh / -t ERROR
Success on install of SuGaR
Success on convertr.py and train.py in quick start.
Problem: cannot convert gaussian splat trained into the textured mesh (--export_uv_textured_mesh / -t )-
I first tried this command to convert to obj/texture - (sugar) C:\Users\Dirk\SuGaR>python train.py -s data/head01 -c output\ -r density [FAILED]
Then I tried -
python -Bu train_coarse_density.py -s data/head01 -c output
[FAILED]
Both of the attempts gave ERROR - train_coarse_density.py: error: unrecognized arguments: -t output\
a snippet of cmd prompt results, I also show 3 different iterations of prompt structures I tried seperated by double spaces , all wrong -
Loading mesh to bind to:
./output/coarse_mesh\head01\sugarmesh_coarse\head01\3Dgs7000_densityestim02_sdfnorm02_level03_decim1000000.ply...
RPly: Unable to open file
[Open3D WARNING] Read PLY failed: unable to open file: ./output/coarse_mesh\head01\sugarmesh_coarse\head01\3Dgs7000_densityestim02_sdfnorm02_level03_decim1000000.ply
Mesh to bind to loaded.
Binding radiance cloud to surface mesh...
Traceback (most recent call last):
File "C:\Users\Dirk\SuGaR\train.py", line 162, in
(sugar) C:\Users\Dirk\SuGaR>python -Bu train_coarse_density.py -s data/head01 -c output\ -t output
usage: train_coarse_density.py [-h] [-c CHECKPOINT_PATH] [-s SCENE_PATH] [-o OUTPUT_DIR] [-i ITERATION_TO_LOAD]
[--eval EVAL] [-e ESTIMATION_FACTOR] [-n NORMAL_FACTOR] [--gpu GPU]
train_coarse_density.py: error: unrecognized arguments: -t output\
(sugar) C:\Users\Dirk\SuGaR>python -Bu train_coarse_density.py -s data/head01 -t output
usage: train_coarse_density.py [-h] [-c CHECKPOINT_PATH] [-s SCENE_PATH] [-o OUTPUT_DIR] [-i ITERATION_TO_LOAD]
[--eval EVAL] [-e ESTIMATION_FACTOR] [-n NORMAL_FACTOR] [--gpu GPU]
train_coarse_density.py: error: unrecognized arguments: -t output\
(sugar) C:\Users\Dirk\SuGaR>python -Bu train_coarse_density.py -s data/head01 -t output\ -r density usage: train_coarse_density.py [-h] [-c CHECKPOINT_PATH] [-s SCENE_PATH] [-o OUTPUT_DIR] [-i ITERATION_TO_LOAD] [--eval EVAL] [-e ESTIMATION_FACTOR] [-n NORMAL_FACTOR] [--gpu GPU] train_coarse_density.py: error: unrecognized arguments: -t output\ -r density
Try this:
python train.py -s data/head01 -c output -r "density"
Hey @HoloDirk,
I see that you got a loading error for the following path, which is wrong:
./output/coarse_mesh\head01\sugarmesh_coarse\head01\3Dgs7000_densityestim02_sdfnorm02_level03_decim1000000.ply
Are you using Windows? If so, please refer to the following issue for more details: https://github.com/Anttwo/SuGaR/issues/37
Windows uses different conventions than Linux for writing paths, and this is the reason why in your case, the code fails in loading the meshes and models during optimization. I will update the code as soon as possible to handle Windows conventions.
Thank you @cubantonystark, Your recommendation was almost right. Appreciate the help in trying to solve
Thank you @Anttwo for providing me the formatting convention for Windows 11 pro running python and issue #37
I re ran the obj/texture command in Win 11 format: (sugar) C:\Users\Dirk\SuGaR>python -t train.py -s data\head01 -c output\ -r "density"
Same error message.
I then ran (sugar) C:\Users\Dirk\SuGaR>python train.py -s data\head01 -c output\ -t output\ -r "density"
Same error message * Re ran the entire training process using Win command guidelines -
procedure:
-
(sugar) C:\Users\Dirk\SuGaR>python gaussian_splatting\convert.py -s data\head01 worked
-
(sugar) C:\Users\Dirk\SuGaR>python gaussian_splatting\convert.py -s data\head01 --skip_matching worked
-
(sugar) C:\Users\Dirk\SuGaR>python -Bu gaussian_splatting\train.py -s data\head01 -m output\head01\ --iterations 30000 --save_iterations 7000 30000 --checkpoint_iterations 7000 30000 trained
-
(sugar) C:\Users\Dirk\SuGaR>python train.py -s data\head01\ -c output\head01\ -r "density" Output - FAILED
- redid step 4 command with -
(sugar) C:\Users\Dirk\SuGaR>python -Bu train_coarse_density.py -s data\head01 -c output\head01
Worked
obj/texture step
5. (sugar) C:\Users\Dirk\SuGaR>python -t train.py -s data\head01 -c output\ -r "density"
AND
(sugar) C:\Users\Dirk\SuGaR>python train.py -s data\head01 -c output\ -r "density"
Both provide ERROR -
Loading config output...
Performing train/eval split...
Traceback (most recent call last):
File "C:\Users\Dirk\SuGaR\train.py", line 120, in
Appreciate the continued help.
Hi. Great Job Anttwo. But I'm trying to solve a little problem. Maybe you can advise something? I'm using ubuntu 22.04 (Mint). The train.py vanilla GS training has been successfully completed. The result is an entire composition of files with a beautiful .ply file playing properly. When training tran.py SuGaR for the second time, unfortunately the process starts but does not end because it does not see the camera.json file. Am I doing something wrong or is this some kind of mistake? Below is a view from the terminal.
python train.py -s data/edit -c gaussian_splatting/output/edit -r density Will export a UV-textured mesh as an .obj file. Will export a ply file with the refined 3D Gaussians at the end of the training. Changing sh_levels to match the loaded model: 4 -----Parsed parameters----- Source path: data/edit
Content: 7 Gaussian Splatting checkpoint path: gaussian_splatting/output/edit Content: 5 SUGAR checkpoint path: ./output/coarse/edit/sugarcoarse_3Dgs7000_densityestim02_sdfnorm02/ Iteration to load: 7000 Output directory: ./output/coarse/edit SDF estimation factor: 0.2 SDF better normal factor: 0.2 Eval split: True White background: False
Using device: 0 |===========================================================================|
| PyTorch CUDA memory summary, device ID 0 |
|---|
| CUDA OOMs: 0 |
| =========================================================================== |
| Metric |
| --------------------------------------------------------------------------- |
| Allocated memory |
| from large pool |
| from small pool |
| --------------------------------------------------------------------------- |
| Active memory |
| from large pool |
| from small pool |
| --------------------------------------------------------------------------- |
| Requested memory |
| from large pool |
| from small pool |
| --------------------------------------------------------------------------- |
| GPU reserved memory |
| from large pool |
| from small pool |
| --------------------------------------------------------------------------- |
| Non-releasable memory |
| from large pool |
| from small pool |
| --------------------------------------------------------------------------- |
| Allocations |
| from large pool |
| from small pool |
| --------------------------------------------------------------------------- |
| Active allocs |
| from large pool |
| from small pool |
| --------------------------------------------------------------------------- |
| GPU reserved segments |
| from large pool |
| from small pool |
| --------------------------------------------------------------------------- |
| Non-releasable allocs |
| from large pool |
| from small pool |
| --------------------------------------------------------------------------- |
| Oversize allocations |
| --------------------------------------------------------------------------- |
| Oversize GPU segments |
| =========================================================================== |
Loading config gaussian_splatting/output/edit...
Performing train/eval split...
Traceback (most recent call last):
File "/home/nocnestudio/NocneStudio/3DGS/SuGaR/train.py", line 129, in
...any advice ;( "No such file or directory" - 100% it's correct directory
THX
Will export a UV-textured mesh as an .obj file. Will export a ply file with the refined 3D Gaussians at the end of the training. Changing sh_levels to match the loaded model: 4 -----Parsed parameters----- Source path: data/edit
Content: 7 Gaussian Splatting checkpoint path: gaussian_splatting/output/edit Content: 5 SUGAR checkpoint path: ./output/coarse/edit/sugarcoarse_3Dgs7000_densityestim02_sdfnorm02/ Iteration to load: 7000 Output directory: ./output/coarse/edit SDF estimation factor: 0.2 SDF better normal factor: 0.2 Eval split: True White background: False
I FOUND SOLUTION - SOLVED !!! ON UBUNTU 22.04 is WORKING. You need to add a slash at the end of the path to the vanilla 3D Gaussian Splatting model. WRONG: python train.py -s data/edit -c gaussian_splatting/output/edit -r density GOOD: python train.py -s data/edit -c gaussian_splatting/output/edit/ -r density
Try this:
WRONG: python train.py -s data/head01 -c output -r "density" GOOD: python train.py -s data/head01 -c output/ -r "density"
I FOUND SOLUTION - SOLVED !!! ON UBUNTU 22.04 is WORKING. You need to add a slash at the end of the path to the vanilla 3D Gaussian Splatting model. WRONG: python train.py -s data/edit -c gaussian_splatting/output/edit -r density GOOD: python train.py -s data/edit -c gaussian_splatting/output/edit/ -r density