Comments (4)
Hi @RaresAmbrus,
Do you have a more descriptive error log? You don't need to trim the interior triangles of your mesh for NGLOD to work, it just helps a bit since the SDF to learn becomes "simpler". You can just return mesh.contiguous()
in that function and the code should normalize properly. AFAIK, the Armadillo mesh is already a 2-manifold so compute_trimmesh()
should return a dense vector of True
in that case (i.e. no triangles are removed).
Hope this helps,
Joey
from nglod.
Thanks @joeylitalien for the quick response! This is the error I get when running the original code:
Traceback (most recent call last):
File "app/main.py", line 62, in <module>
model = Trainer(args, args_str, 'mesh')
File "/workspace/nglod/sdf-net/lib/trainer.py", line 122, in __init__
self.set_dataset()
File "/workspace/nglod/sdf-net/lib/trainer.py", line 161, in set_dataset
self.train_dataset = globals()[self.args.mesh_dataset](self.args)
File "/workspace/nglod/sdf-net/lib/datasets/MeshDataset.py", line 71, in __init__
self.ids, self.p, self.d, self.nrm = self._sample()
File "/workspace/nglod/sdf-net/lib/datasets/MeshDataset.py", line 81, in _sample
pts = point_sample(self.mesh, self.sample_mode, self.num_samples)
File "/workspace/nglod/sdf-net/lib/torchgp/point_sample.py", line 39, in point_sample
distrib = area_weighted_distribution(mesh)
File "/workspace/nglod/sdf-net/lib/torchgp/area_weighted_distribution.py", line 40, in area_weighted_distribution
return torch.distributions.Categorical(areas.view(-1))
File "/usr/local/lib/python3.6/dist-packages/torch/distributions/categorical.py", line 64, in __init__
super(Categorical, self).__init__(batch_shape, validate_args=validate_args)
File "/usr/local/lib/python3.6/dist-packages/torch/distributions/distribution.py", line 53, in __init__
raise ValueError("The parameter {} has invalid values".format(param))
ValueError: The parameter probs has invalid values
For some reason all the triangles are removed and data/armadillo_normalized.obj
is just an empty file. Maybe just a local issue with my setup.
Returning directly mesh.contiguous()
as you suggested seems to work - it's training now! Maybe as a follow-up, I'm getting very low losses:
[27/07 20:38:39] [INFO] Loaded mesh dataset
[27/07 20:38:39] [INFO] Total number of parameters: 10146213
[27/07 20:38:39] [INFO] Model configured and ready to go
[27/07 20:38:54] [INFO] EPOCH 1/251 | total loss: 6.702E-03 | l2 loss: 1.071E-03
[27/07 20:38:54] [INFO] Saving model checkpoint to: _results/models/armadillo.pth
[27/07 20:39:15] [INFO] EPOCH 2/251 | total loss: 5.059E-04 | l2 loss: 7.187E-05
[27/07 20:39:15] [INFO] Saving model checkpoint to: _results/models/armadillo.pth
Does that look good? Thanks again for the help!
from nglod.
Yes, these types of losses are typical. Honestly I wouldn't worry too much about the interior triangle trimming; in practice it does little to no difference if you have a high quality mesh.
from nglod.
Ok great, thanks again @joeylitalien!
from nglod.
Related Issues (20)
- mesh2sdf errors HOT 6
- Crash using Kaolin SPC HOT 2
- Building sol-rendere: CMAKE_CUDA_COMPILER not set, after EnableLanguage
- Render OBJ files HOT 2
- Question about modeling a 3d shape using marching cube HOT 5
- Question about generate parents in create_trinkets.
- Installation Help HOT 2
- Rendering on Mobile
- The accuracy of predicted sdf function
- ModuleNotFoundError: No module named 'sol_nglod'
- Mismatched model size for different LODs HOT 1
- Args to Export .npz File HOT 4
- Can't export .npz files HOT 1
- abbreviation problem HOT 1
- Can you share chamfer distance evaluation code for SPC part?
- Training with surface normal / sdf gradient supervision HOT 1
- Storage problem of your paper HOT 2
- About rendering 3D models HOT 1
- Building CUDA extensions failed HOT 1
- ShapeNet150 data HOT 2
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from nglod.