tecio-python 0.4.1__tar.gz → 0.4.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (52) hide show
  1. {tecio_python-0.4.1/tecio_python.egg-info → tecio_python-0.4.2}/PKG-INFO +9 -9
  2. {tecio_python-0.4.1 → tecio_python-0.4.2}/README.md +8 -8
  3. {tecio_python-0.4.1 → tecio_python-0.4.2}/plugins/paraview/TecplotTecioReader.py +1 -1
  4. {tecio_python-0.4.1 → tecio_python-0.4.2}/pyproject.toml +3 -2
  5. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/__init__.py +42 -1
  6. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/_dat_write.py +32 -0
  7. tecio_python-0.4.2/tecio/_elements.py +1311 -0
  8. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/_io.py +49 -4
  9. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/_meta.py +8 -0
  10. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/_plt_write.py +32 -0
  11. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/_reader.py +157 -3
  12. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/_szl_read.py +99 -3
  13. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/_szl_write.py +261 -0
  14. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/_utils.py +10 -10
  15. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/_writer.py +234 -3
  16. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/cli/tec2mat.py +20 -0
  17. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/cli/tecaux.py +11 -1
  18. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/cli/tecdump.py +24 -1
  19. tecio_python-0.4.2/tecio/cli/tecelretyp.py +1096 -0
  20. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/cli/tecextract.py +21 -2
  21. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/cli/tecfix.py +16 -1
  22. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/cli/tecmerge.py +226 -34
  23. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/cli/teconvert.py +12 -2
  24. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/cli/tecscale.py +16 -1
  25. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/cli/tecslice.py +24 -3
  26. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/libtecio.py +75 -6
  27. {tecio_python-0.4.1 → tecio_python-0.4.2/tecio_python.egg-info}/PKG-INFO +9 -9
  28. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio_python.egg-info/SOURCES.txt +3 -0
  29. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio_python.egg-info/entry_points.txt +1 -0
  30. {tecio_python-0.4.1 → tecio_python-0.4.2}/tests/test_cli.py +542 -1
  31. tecio_python-0.4.2/tests/test_elements.py +1971 -0
  32. {tecio_python-0.4.1 → tecio_python-0.4.2}/tests/test_io.py +0 -0
  33. {tecio_python-0.4.1 → tecio_python-0.4.2}/tests/test_libtecio.py +0 -0
  34. {tecio_python-0.4.1 → tecio_python-0.4.2}/tests/test_read.py +131 -0
  35. {tecio_python-0.4.1 → tecio_python-0.4.2}/tests/test_read_legacy.py +0 -0
  36. {tecio_python-0.4.1 → tecio_python-0.4.2}/tests/test_write.py +492 -0
  37. {tecio_python-0.4.1 → tecio_python-0.4.2}/LICENSE +0 -0
  38. {tecio_python-0.4.1 → tecio_python-0.4.2}/NOTICE +0 -0
  39. {tecio_python-0.4.1 → tecio_python-0.4.2}/plugins/matlab/contourfe.m +0 -0
  40. {tecio_python-0.4.1 → tecio_python-0.4.2}/plugins/matlab/tecmat2struct.m +0 -0
  41. {tecio_python-0.4.1 → tecio_python-0.4.2}/plugins/paraview/TecplotTecioWriter.py +0 -0
  42. {tecio_python-0.4.1 → tecio_python-0.4.2}/setup.cfg +0 -0
  43. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/_constants.py +2 -2
  44. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/_containers.py +0 -0
  45. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/_dat_read.py +0 -0
  46. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/_plt_legacy.py +0 -0
  47. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/_plt_read.py +0 -0
  48. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/cli/__init__.py +0 -0
  49. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio/cli/tecstats.py +0 -0
  50. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio_python.egg-info/dependency_links.txt +0 -0
  51. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio_python.egg-info/requires.txt +0 -0
  52. {tecio_python-0.4.1 → tecio_python-0.4.2}/tecio_python.egg-info/top_level.txt +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: tecio-python
3
- Version: 0.4.1
3
+ Version: 0.4.2
4
4
  Summary: Python interface for reading and writing Tecplot data files
5
5
  License-Expression: Apache-2.0
6
6
  Project-URL: Homepage, https://github.com/meersman/tecio-python
@@ -61,9 +61,9 @@ Dynamic: license-file
61
61
  # tecio
62
62
 
63
63
  [![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](LICENSE)
64
- [![CI](https://github.com/meersman/tecio/actions/workflows/ci.yml/badge.svg)](https://github.com/meersman/tecio/actions/workflows/ci.yml)
65
- [![Codecov](https://codecov.io/gh/meersman/tecio/branch/main/graph/badge.svg)](https://codecov.io/gh/meersman/tecio)
66
- [![Docs](https://github.com/meersman/tecio/actions/workflows/docs.yml/badge.svg)](https://meersman.github.io/tecio)
64
+ [![CI](https://github.com/meersman/tecio-python/actions/workflows/ci.yml/badge.svg)](https://github.com/meersman/tecio/actions/workflows/ci.yml)
65
+ [![Codecov](https://codecov.io/gh/meersman/tecio-python/branch/main/graph/badge.svg)](https://codecov.io/gh/meersman/tecio-python)
66
+ [![Docs](https://github.com/meersman/tecio-python/actions/workflows/docs.yml/badge.svg)](https://meersman.github.io/tecio-python)
67
67
  [![PyPI](https://img.shields.io/pypi/v/tecio-python)](https://pypi.org/project/tecio-python)
68
68
  [![Python](https://img.shields.io/pypi/pyversions/tecio-python)](https://pypi.org/project/tecio-python)
69
69
 
@@ -155,13 +155,13 @@ Contributions are welcome (see [CONTRIBUTING.md](CONTRIBUTING.md) for details).
155
155
 
156
156
  - [Tecplot data format specification](https://tecplot.azureedge.net/products/360/current/360-data-format.html)
157
157
  - [TecIO library](https://tecplot.com/products/tecio-library/)
158
- - [Full documentation](https://meersman.github.io/tecio)
158
+ - [Full documentation](https://meersman.github.io/tecio-python)
159
159
 
160
160
  ---
161
161
 
162
162
  ## Disclaimer
163
163
 
164
- This project is an independent open source library and is not affiliated
165
- with, endorsed by, or supported by Tecplot, Inc. in any way. Tecplot and
166
- TecIO are trademarks of Tecplot, Inc. Use of the TecIO library requires a
167
- separate license from Tecplot, Inc.
164
+ This project is an independent open source library and is not affiliated with,
165
+ endorsed by, or supported by Tecplot, Inc. in any way. Tecplot and TecIO are
166
+ trademarks of Tecplot, Inc. Use of the TecIO library requires separatly
167
+ aquiring the source code or compiled binaries from Tecplot, Inc.
@@ -1,9 +1,9 @@
1
1
  # tecio
2
2
 
3
3
  [![License](https://img.shields.io/badge/License-Apache%202.0-blue.svg)](LICENSE)
4
- [![CI](https://github.com/meersman/tecio/actions/workflows/ci.yml/badge.svg)](https://github.com/meersman/tecio/actions/workflows/ci.yml)
5
- [![Codecov](https://codecov.io/gh/meersman/tecio/branch/main/graph/badge.svg)](https://codecov.io/gh/meersman/tecio)
6
- [![Docs](https://github.com/meersman/tecio/actions/workflows/docs.yml/badge.svg)](https://meersman.github.io/tecio)
4
+ [![CI](https://github.com/meersman/tecio-python/actions/workflows/ci.yml/badge.svg)](https://github.com/meersman/tecio/actions/workflows/ci.yml)
5
+ [![Codecov](https://codecov.io/gh/meersman/tecio-python/branch/main/graph/badge.svg)](https://codecov.io/gh/meersman/tecio-python)
6
+ [![Docs](https://github.com/meersman/tecio-python/actions/workflows/docs.yml/badge.svg)](https://meersman.github.io/tecio-python)
7
7
  [![PyPI](https://img.shields.io/pypi/v/tecio-python)](https://pypi.org/project/tecio-python)
8
8
  [![Python](https://img.shields.io/pypi/pyversions/tecio-python)](https://pypi.org/project/tecio-python)
9
9
 
@@ -95,13 +95,13 @@ Contributions are welcome (see [CONTRIBUTING.md](CONTRIBUTING.md) for details).
95
95
 
96
96
  - [Tecplot data format specification](https://tecplot.azureedge.net/products/360/current/360-data-format.html)
97
97
  - [TecIO library](https://tecplot.com/products/tecio-library/)
98
- - [Full documentation](https://meersman.github.io/tecio)
98
+ - [Full documentation](https://meersman.github.io/tecio-python)
99
99
 
100
100
  ---
101
101
 
102
102
  ## Disclaimer
103
103
 
104
- This project is an independent open source library and is not affiliated
105
- with, endorsed by, or supported by Tecplot, Inc. in any way. Tecplot and
106
- TecIO are trademarks of Tecplot, Inc. Use of the TecIO library requires a
107
- separate license from Tecplot, Inc.
104
+ This project is an independent open source library and is not affiliated with,
105
+ endorsed by, or supported by Tecplot, Inc. in any way. Tecplot and TecIO are
106
+ trademarks of Tecplot, Inc. Use of the TecIO library requires separatly
107
+ aquiring the source code or compiled binaries from Tecplot, Inc.
@@ -1204,7 +1204,7 @@ class TecplotReader(VTKPythonAlgorithmBase):
1204
1204
  f"zone type {zone.zone_type.name} is not yet supported by this "
1205
1205
  "reader (only ORDERED, classic FE zones -- line, triangle, "
1206
1206
  "quadrilateral, tetrahedron, brick -- polygon, and polyhedron "
1207
- "zones are converted; mixed zones are not)"
1207
+ "zones are converted; FEMIXED zones are not)"
1208
1208
  )
1209
1209
  dataset = self._build_unstructured_grid(
1210
1210
  zone, cell_type, x_name, y_name, z_name
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "tecio-python"
7
- version = "0.4.1"
7
+ version = "0.4.2"
8
8
  license = "Apache-2.0"
9
9
  description = "Python interface for reading and writing Tecplot data files"
10
10
 
@@ -41,6 +41,7 @@ tec2mat = "tecio.cli.tec2mat:main"
41
41
  tecaux = "tecio.cli.tecaux:main"
42
42
  teconvert = "tecio.cli.teconvert:main"
43
43
  tecdump = "tecio.cli.tecdump:main"
44
+ tecelretyp = "tecio.cli.tecelretyp:main"
44
45
  tecextract = "tecio.cli.tecextract:main"
45
46
  tecfix = "tecio.cli.tecfix:main"
46
47
  tecmerge = "tecio.cli.tecmerge:main"
@@ -160,7 +161,7 @@ output-format = "concise"
160
161
  include = ["plugins/**"]
161
162
 
162
163
  [tool.ty.overrides.rules]
163
- unresolved-import = "ignore"
164
+ import-not-found = "ignore"
164
165
 
165
166
  [tool.pytest.ini_options]
166
167
  pythonpath = ["tecio"]
@@ -11,7 +11,7 @@ from importlib import metadata
11
11
  try:
12
12
  __version__ = metadata.version("tecio")
13
13
  except metadata.PackageNotFoundError:
14
- __version__ = "0.4.1"
14
+ __version__ = "0.4.2"
15
15
 
16
16
  from . import cli, libtecio
17
17
  from ._constants import (
@@ -30,6 +30,19 @@ from ._constants import (
30
30
  from ._containers import VariableList, ZoneList
31
31
  from ._dat_read import TecplotDatReader
32
32
  from ._dat_write import TecplotDatWriter
33
+ from ._elements import (
34
+ UNKNOWN_SHAPE,
35
+ cell_face_neighbors,
36
+ classify_cells,
37
+ collapse_cells,
38
+ collapsed_zone_type,
39
+ degenerate_edges,
40
+ expand_cells,
41
+ match_cells,
42
+ match_nodes,
43
+ shape_counts,
44
+ split_cells_by_shape,
45
+ )
33
46
  from ._io import (
34
47
  AppendReadWrite,
35
48
  AppendWrite,
@@ -48,6 +61,7 @@ from ._plt_read import TecplotPltReader
48
61
  from ._plt_write import TecplotPltWriter
49
62
  from ._reader import (
50
63
  TecplotAuxDataReader,
64
+ TecplotFEMixedZoneReader,
51
65
  TecplotFEZoneReader,
52
66
  TecplotOrderedZoneReader,
53
67
  TecplotPolyZoneReader,
@@ -62,6 +76,20 @@ from ._writer import EmptyZoneWarning, TecplotWriter
62
76
  # Ensure these display as their canonical public name in docs and help(),
63
77
  # rather than the private module they're actually defined in.
64
78
  open.__module__ = "tecio"
79
+ for _func in (
80
+ cell_face_neighbors,
81
+ classify_cells,
82
+ collapse_cells,
83
+ collapsed_zone_type,
84
+ degenerate_edges,
85
+ expand_cells,
86
+ match_cells,
87
+ match_nodes,
88
+ shape_counts,
89
+ split_cells_by_shape,
90
+ ):
91
+ _func.__module__ = "tecio"
92
+ del _func
65
93
  for _cls in (
66
94
  AppendWrite,
67
95
  AppendReadWrite,
@@ -71,6 +99,7 @@ for _cls in (
71
99
  TecplotZoneReader,
72
100
  TecplotOrderedZoneReader,
73
101
  TecplotFEZoneReader,
102
+ TecplotFEMixedZoneReader,
74
103
  TecplotPolyZoneReader,
75
104
  TecplotVariableReader,
76
105
  TecplotAuxDataReader,
@@ -118,6 +147,7 @@ __all__ = [
118
147
  "TecplotZoneReader",
119
148
  "TecplotOrderedZoneReader",
120
149
  "TecplotFEZoneReader",
150
+ "TecplotFEMixedZoneReader",
121
151
  "TecplotPolyZoneReader",
122
152
  "TecplotVariableReader",
123
153
  "TecplotAuxDataReader",
@@ -129,6 +159,17 @@ __all__ = [
129
159
  "TecplotPltWriter",
130
160
  "TecplotDatWriter",
131
161
  "EmptyZoneWarning",
162
+ "UNKNOWN_SHAPE",
163
+ "cell_face_neighbors",
164
+ "classify_cells",
165
+ "collapse_cells",
166
+ "collapsed_zone_type",
167
+ "degenerate_edges",
168
+ "expand_cells",
169
+ "match_cells",
170
+ "match_nodes",
171
+ "shape_counts",
172
+ "split_cells_by_shape",
132
173
  "Boolean",
133
174
  "DataPacking",
134
175
  "DataType",
@@ -27,6 +27,7 @@ from ._constants import (
27
27
  DataPacking,
28
28
  DataType,
29
29
  FaceNeighborMode,
30
+ FeCellShape,
30
31
  FileType,
31
32
  ValueLocation,
32
33
  ZoneType,
@@ -938,6 +939,37 @@ class TecplotDatWriter(TecplotWriter):
938
939
  )
939
940
  )
940
941
 
942
+ def write_femixed_zone(
943
+ self,
944
+ data: Sequence[npt.ArrayLike],
945
+ cell_shapes: Sequence[FeCellShape | int | str] | None = None,
946
+ node_maps: Sequence[npt.ArrayLike] | None = None,
947
+ *,
948
+ title: str | None = None,
949
+ variables: list[str] | None = None,
950
+ value_locations: Sequence[ValueLocation] | None = None,
951
+ passive_vars: PassiveVarsSpec | None = None,
952
+ var_sharing: VarSharingSpec | None = None,
953
+ con_sharing: int | None = None,
954
+ solution_time: float = 0.0,
955
+ strand_id: int = 0,
956
+ aux: dict[str, Any] | None = None,
957
+ datapacking: DataPacking | str = DataPacking.BLOCK,
958
+ ) -> None:
959
+ """Not supported: DAT files cannot hold FEMIXED zones.
960
+
961
+ The signature matches :meth:`TecplotSzlWriter.write_femixed_zone` so every
962
+ writer exposes the same interface.
963
+
964
+ Raises:
965
+ NotImplementedError: Always. Write a ``.szplt`` file instead, see
966
+ :meth:`TecplotSzlWriter.write_femixed_zone`.
967
+ """
968
+ raise NotImplementedError(
969
+ "The DAT file format does not support FEMIXED (mixed finite-element) "
970
+ "zones. Write a .szplt file instead."
971
+ )
972
+
941
973
  def write_poly_zone(
942
974
  self,
943
975
  data: Sequence[npt.ArrayLike],