Comments (8)
Hi @liangqianqian123 ,
When encountering "bad" (valence 3) vertices (aka "invalids"), we clean them if possible. The issue is that these "valence 3" vertices cause many edges to be unable to be collapsed. See this illustration, on the left is a valid edge collapse, on the right is a collapse which results in a non-manifold geometry:
When we encounter such a vertex we clean it.
from meshcnn.
@ranahanocka , Thanks for the reply. I also encounter a problem about the invalid edges.
In my case, the __remove_triplete get asserted after getting the invalid_edges.
The invalid_edges = [3534, 3547, 3543].
def __remove_triplete(mesh, mask, edge_groups, invalid_edges):
vertex = set(mesh.edges[invalid_edges[0]])
for edge_key in invalid_edges:
vertex &= set(mesh.edges[edge_key])
mask[edge_key] = False
MeshPool.__remove_group(mesh, edge_groups, edge_key)
mesh.edges_count -= 3
vertex = list(vertex)
assert(len(vertex) == 1)
The assert(len(vertex) ==1) is triggered. I debugged a little bit is that: it seems it is caused by wrong neighbour information. The label information is as below:
edge id: gemm_edge
3534 [3547 3543 3547 3543]
3543 [3547 3534 3547 3534]
3547 [3543 3534 3543 3534]
Have you encounter this problem before? What could be the reason and any recommendation to solve the problem?
Thanks & Regards,
Spencer
from meshcnn.
@ranahanocka , I found the answer from #7, so it is caused due to a very small connected but isolated component. Do you have any idea that how we can solve it in programming way?
from meshcnn.
Hi @chengzg ,
You can remove small connected components using meshlab (via scripting).
from meshcnn.
Hi @ranahanocka ,
Thanks very much for your reply.
I am thinking of solving the problem in MeshCNN code. For example, in the scenario mentioned above, i could delete the whole triangle or adding another array to reduce its priority to be collapsed. Do you think will it work?
Also you added the assert there, it must be some reason. May i know what problem you have experienced before?
Thanks & Regards,
Spencer
from meshcnn.
Hi @chengzg ,
It is certainly possible, but it is more complicated. I believe meshlab is an easier approach. Here is a script which will do it
<!DOCTYPE FilterScript>
<FilterScript>
<filter name="Remove Isolated pieces (wrt Face Num.)">
<Param type="RichInt" value="25" name="MinComponentSize"/>
</filter>
<filter name="Remove Unreferenced Vertex"/>
</FilterScript>
You need to save that to a file and call it something that ends with .mlx, for example remove_island.mlx. Also, install meshlab and then you can call it from the command line:
meshlabserver -i cube.obj -s remove_island.mlx -o cube_out.obj
where cube.obj is the input file and cube_out.obj is the output file.
from meshcnn.
Also you added the assert there, it must be some reason. May i know what problem you have experienced before?
So if the smallest connected component (a pyramid object) cannot have any more edges removed. It is the smallest genus-0 primitive that exists. Basically, removing an edge on this small object will result in non-manifold geometry.
from meshcnn.
Again thanks very much for your reply.
Thanks & Regards,
Spencer
from meshcnn.
Related Issues (20)
- IndexError: index out of range
- AssertionError
- What is the relationship between your meshes and original coseg meshes?
- Segmentation of objects with different characteristic
- assert no zero face area
- Does the class "Mesh" have an attribute about face?
- Undestanding .eseg file
- Proper TensorBoard Usage
- How to prepare data for a custom dataset?
- cannot install pytorch=1.2.0 HOT 1
- How to save a segmented (colored) mesh in .obj format?
- IndexError: index out of range
- Using my own obj files for training
- The problem when I run meshcnn classification HOT 1
- Problems with date preprocessing.
- help in figuring out how human_seg dataset was created
- Cannot load pre-trained weights
- Request for further documentation of code options on the meshcnn wiki for the Classification task
- Numpy error? HOT 2
- A small spelling mistake in the paper
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 meshcnn.