Comments (7)
Hi,
I usually open the VTU file with python vtk or Paraview. In am not sure for certain, but I suspect the six values per line just means you have two 3D points per line, not a single 3D point on each line.
I can look into this a bit further - it would help it you attached your VTU file for me to look at.
Cheers,
Michael
from pyoctree.
Here is a zip of the octree.vtu file, which is just the result of running your introductory example on the knot.stl geometry. It works fine in paraview actually, but i'd like to extract such data points and thus need to be sure of what i'm looking at.
Also there is a data array at the end with 6 integers per line (value of 12 here)...I wonder what is the use for it?
Thanks a lot!
from pyoctree.
As I thought, the 6 points are just two 3D points per line (you can tell from the total number of points, which is 19976, spread over half as many lines in the file).
The next integers are the cells (i.e. each line here is the list of points that form each cell. Note there are 8 points forming each cell)
The next integers (value of 12) correspond to the element types. Element type 12 is the 8 noded vtk_hexahedron.
from pyoctree.
Ok thanks a lot for your feedback. For cells connectivity it's the same deal I suppose, 6 integers per line but it really is 8 consecutive ints that form a cell. I'm surprised it doesn't disturb paraview.
Also I just realized there is also an "offsets" data array with about 6 integers per line, for a total of 2497 elements, just like the number of cells. Is it used to designate the reference point for the vtk elements (just guessing)?
from pyoctree.
This doesn't worry Paraview because it knows what each cell type is and therefore how many points it should read to form each cell. This is also where the offset is used. That is, if you look at the offset values they are 8, 16, 24, 32, 40, 48, 56 etc. This tells paraview that the starting point for the first cell is 0, for the second cell is 8, for the third cell is 16 etc.
The best document on vtk file formats that I have found (although several years old) is:
https://vtk.org/wp-content/uploads/2015/04/file-formats.pdf
from pyoctree.
Alright makes sense, thank you very much for this information
from pyoctree.
No problem
from pyoctree.
Related Issues (20)
- Multiprocessing and PyOctree error HOT 4
- c++ version of PyOctree HOT 2
- 4D and custom distance metrics
- What exactly is connectivity? HOT 2
- stop octree decomposition by node size? HOT 1
- Unexpected behaviour of octree result
- Fatal error C1083: Cannot open source file: 'pyoctree/pyoctree.cpp' HOT 1
- Non-square bounding box ?
- Pyoctree not finding intersections
- General Query regarding octree mesh HOT 2
- Partialy hollowing mesh
- What needs to be done to use doubles instead of floats? HOT 3
- How do I get the coordinates, size, and node IDs of all the leaf nodes in an octree?
- Computing intersections over float values instead of dtype= dtype=np.float32, using dev version functionality. HOT 2
- Installation difficulties from tp_print
- How to update any node from octree
- thread safety?
- Mesh face edges no intersect with ray
- C++ example usage
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 pyoctree.