Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Implement missing features to enable compatibility with python's meshio #22

Closed
wants to merge 16 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 3 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
/target
/target_remote
**/*.rs.bk
Cargo.lock
.vscode
.DS_Store
.idea
/assets/proto
2 changes: 1 addition & 1 deletion assets/box.vtu
Original file line number Diff line number Diff line change
@@ -1 +1 @@
<VTKFile type="UnstructuredGrid" version="4.2" byte_order="BigEndian"><UnstructuredGrid><Piece NumberOfPoints="8" NumberOfCells="6" NumberOfLines="0" NumberOfStrips="0" NumberOfPolys="0" NumberOfVerts="0"><PointData Scalars="pressure" Vectors="Cd"><DataArray type="Float32" Name="pressure" format="binary" NumberOfComponents="1">AAAAAAAAAAS/AAAAvwAAAD8AAAA/AAAAvwAAAL8AAAA/AAAAPwAAAA==</DataArray><DataArray type="Float32" Name="Cd" format="binary" NumberOfComponents="3">AAAAAAAAAAQ+TMzNAAAAAD+AAAA+TMzNAAAAAD+AAAAAAAAAP4AAAD3MzM0AAAAAP4AAAD3MzM0+TMzNAAAAAD+AAAA+TMzNAAAAAD+AAAAAAAAAP4AAAD3MzM0AAAAAP4AAAD3MzM0=</DataArray><DataArray type="Int32" Name="mtl_id" format="binary" NumberOfComponents="1">AAAAAAAAAAQAAAABAAAAAQAAAAEAAAABAAAAAQAAAAEAAAABAAAAAQ==</DataArray></PointData><CellData Scalars="mtl_id"><DataArray type="Int32" Name="mtl_id" format="binary" NumberOfComponents="1">AAAAAAAAAAQAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=</DataArray></CellData><Points><DataArray type="Float64" format="binary" NumberOfComponents="3">AAAAAAAAAAg/4KqqoAAAAL/gAAAAAAAAP+AAAAAAAAC/4KqqoAAAAL/gAAAAAAAAP+AAAAAAAAA/4KqqoAAAAD/gAAAAAAAAP+AAAAAAAAC/4KqqoAAAAD/gAAAAAAAAP+AAAAAAAAC/4KqqoAAAAL/gAAAAAAAAv+AAAAAAAAA/4KqqoAAAAL/gAAAAAAAAv+AAAAAAAAC/4KqqoAAAAD/gAAAAAAAAv+AAAAAAAAA/4KqqoAAAAD/gAAAAAAAAv+AAAAAAAAA=</DataArray></Points><Cells><DataArray type="UInt64" Name="connectivity" format="binary" NumberOfComponents="1">AAAAAAAAAAgAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAMAAAAAAAAAAgAAAAAAAAAEAAAAAAAAAAUAAAAAAAAABwAAAAAAAAAGAAAAAAAAAAYAAAAAAAAABwAAAAAAAAACAAAAAAAAAAMAAAAAAAAABQAAAAAAAAAEAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAgAAAAAAAAAHAAAAAAAAAAEAAAAAAAAABAAAAAAAAAAGAAAAAAAAAAM=</DataArray><DataArray type="UInt64" Name="offsets" format="binary" NumberOfComponents="1">AAAAAAAAAAgAAAAAAAAABAAAAAAAAAAIAAAAAAAAAAwAAAAAAAAAEAAAAAAAAAAUAAAAAAAAABg=</DataArray><DataArray type="UInt8" Name="types" format="binary" NumberOfComponents="1">AAAAAAAAAAEHBwcHBwc=</DataArray></Cells></Piece></UnstructuredGrid></VTKFile>
<VTKFile type="UnstructuredGrid" version="4.2" byte_order="BigEndian" header_type="UInt64"><UnstructuredGrid><Piece NumberOfPoints="8" NumberOfCells="6" NumberOfLines="0" NumberOfStrips="0" NumberOfPolys="0" NumberOfVerts="0"><PointData Scalars="pressure" Vectors="Cd"><DataArray type="Float32" Name="pressure" format="binary" NumberOfComponents="1">AAAAAAAAACC/AAAAvwAAAD8AAAA/AAAAvwAAAL8AAAA/AAAAPwAAAA==</DataArray><DataArray type="Float32" Name="Cd" format="binary" NumberOfComponents="3">AAAAAAAAAGA+TMzNAAAAAD+AAAA+TMzNAAAAAD+AAAAAAAAAP4AAAD3MzM0AAAAAP4AAAD3MzM0+TMzNAAAAAD+AAAA+TMzNAAAAAD+AAAAAAAAAP4AAAD3MzM0AAAAAP4AAAD3MzM0=</DataArray><DataArray type="Int32" Name="mtl_id" format="binary" NumberOfComponents="1">AAAAAAAAACAAAAABAAAAAQAAAAEAAAABAAAAAQAAAAEAAAABAAAAAQ==</DataArray></PointData><CellData Scalars="mtl_id"><DataArray type="Int32" Name="mtl_id" format="binary" NumberOfComponents="1">AAAAAAAAABgAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA=</DataArray></CellData><Points><DataArray type="Float64" format="binary" NumberOfComponents="3">AAAAAAAAAMA/4KqqoAAAAL/gAAAAAAAAP+AAAAAAAAC/4KqqoAAAAL/gAAAAAAAAP+AAAAAAAAA/4KqqoAAAAD/gAAAAAAAAP+AAAAAAAAC/4KqqoAAAAD/gAAAAAAAAP+AAAAAAAAC/4KqqoAAAAL/gAAAAAAAAv+AAAAAAAAA/4KqqoAAAAL/gAAAAAAAAv+AAAAAAAAC/4KqqoAAAAD/gAAAAAAAAv+AAAAAAAAA/4KqqoAAAAD/gAAAAAAAAv+AAAAAAAAA=</DataArray></Points><Cells><DataArray type="UInt64" Name="connectivity" format="binary" NumberOfComponents="1">AAAAAAAAAMAAAAAAAAAAAAAAAAAAAAABAAAAAAAAAAMAAAAAAAAAAgAAAAAAAAAEAAAAAAAAAAUAAAAAAAAABwAAAAAAAAAGAAAAAAAAAAYAAAAAAAAABwAAAAAAAAACAAAAAAAAAAMAAAAAAAAABQAAAAAAAAAEAAAAAAAAAAEAAAAAAAAAAAAAAAAAAAAFAAAAAAAAAAAAAAAAAAAAAgAAAAAAAAAHAAAAAAAAAAEAAAAAAAAABAAAAAAAAAAGAAAAAAAAAAM=</DataArray><DataArray type="UInt64" Name="offsets" format="binary" NumberOfComponents="1">AAAAAAAAADAAAAAAAAAABAAAAAAAAAAIAAAAAAAAAAwAAAAAAAAAEAAAAAAAAAAUAAAAAAAAABg=</DataArray><DataArray type="UInt8" Name="types" format="binary" NumberOfComponents="1">AAAAAAAAAAYHBwcHBwc=</DataArray></Cells></Piece></UnstructuredGrid></VTKFile>
181 changes: 181 additions & 0 deletions assets/pygmsh/ascii.vtk
Original file line number Diff line number Diff line change
@@ -0,0 +1,181 @@
# vtk DataFile Version 5.1
written by meshio v5.3.0
ASCII
DATASET UNSTRUCTURED_GRID
POINTS 18 double
0.0 0.0 0.0 1.0 -0.2 0.0 1.1 1.2 0.0 0.1 0.7 0.0 0.3333333333325021 -0.06666666666650042 0.0 0.6666666666657866 -0.1333333333331573 0.0 1.0249999999999424 0.14999999999919245 0.0 1.0499999999998704 0.4999999999981836 0.0 1.074999999999934 0.8499999999990746 0.0 0.766666666667985 1.0333333333339925 0.0 0.433333333334733 0.8666666666673664 0.0 0.050000000000122564 0.3500000000008579 0.0 0.7444729167676052 0.3524793413776178 0.0 0.3781088913238718 0.4816987298113132 0.0 0.7412636346823331 0.6806963451979247 0.0 0.5070791452210437 0.16277273408010906 0.0 0.253704273975508 0.18556095944515594 0.0 0.7797139636550688 0.08823831456107314 0.0
CELLS 39 94
OFFSETS vtktypeint64
0
2
4
6
8
10
12
14
16
18
20
22
24
27
30
33
36
39
42
45
48
51
54
57
60
63
66
69
72
75
78
81
84
87
90
91
92
93
94
CONNECTIVITY vtktypeint64
0
4
4
5
5
1
1
6
6
7
7
8
8
2
2
9
9
10
10
3
3
11
11
0
10
13
14
13
12
14
10
3
13
8
2
9
4
5
15
9
10
14
3
11
13
6
7
12
8
9
14
7
8
14
12
7
14
15
5
17
5
1
17
1
6
17
12
13
15
13
11
16
15
13
16
11
0
16
0
4
16
6
12
17
12
15
17
4
15
16
0
1
2
3
CELL_TYPES 38
3
3
3
3
3
3
3
3
3
3
3
3
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
5
1
1
1
1
Loading