Repository navigation
Releases
v0.4.3
0.4.3
Patch release fixing the PLT reader for cell-centered data in
lower-dimensional ordered zones and adding a new console script.
Added
tectableconsole script converts a delimited text table to Tecplot zones
with additional flags for filtering or grouping like data into zones.
Fixed
- The PLT reader sized cell-centered variables of ordered zones as
I*J*(K-1)
values for every zone. TecIO pads every dimension except the last one with
more than one node. So the PLT reader did not correctly calculate the number
of values to read for cell-centered data in one or two dimension while in
three dimensions the correct number of values were read. This bug did not
affect SZL or DAT readers.
Full changelog: v0.4.2...v0.4.3
v0.4.2
0.4.2
Added FEMIXED support and unstructured data utilities.
Added
- Node-map utilities for classic finite-element zones, importable from
tecio:classify_cells,shape_countsanddegenerate_edgesdetect cells
written asFEBRICKorFEQUADRILATERALwith repeated node indices
(tetrahedra, pyramids, prisms, triangles).collapsed_zone_typeandcollapse_cellscollapse such cells to their
natural zone type (FEBRICKtoFETETRAHEDRON,FEQUADRILATERALto
FETRIANGLE) and keep the cell handedness.expand_cellsgoes the other
way.split_cells_by_shapeseparates padded cells in aFEBRICKor
FEQUADRILATERALzone by shape for writing them as aFEMIXED
zone. Pyramids and prisms keep the handedness of the brick they came from.cell_face_neighborsfinds the cell across every face of every cell from
the node map alone, for triangles, quadrilaterals, tetrahedra and
bricks. It returns-1for boundary faces.match_nodesandmatch_cellsfind how the nodes and cells of a zone are
ordered relative to a reference zone with the same grid since multiple
cell orderings could be used for identical unstructured meshes. They
return the orders that put nodal and cell-centered variables in the
reference order, orNoneif the zones do not match.
TecplotPolyZoneReader.element_faces()andelement_nodes()return the
faces and the distinct nodes of every element of a polygon or polyhedron
zone as(offsets, flat_array), built from the face left and right
elements.tecelretypconsole script retypes FE zones whose cells are all upcast with
repeated nodes, which gives a more compact node map and more descriptive
zone metadata.- FEMIXED (mixed finite-element) zones suppport (read and write) for SZPLT
files.
Changed
tecmerge --merge-gridnow compares the grid variables and, for classic FE
zones, the connectivity of zones before sharing. A zone with the same grid
stored in another node and cell order (e.g. the same mesh in PLT and SZL)
shares the grid and has its nodal and cell-centered variables reordered to
match. Zones not matching the connectivity in any order retain their grid.
Full changelog: v0.4.1...v0.4.2
v0.4.1
0.4.1
Polyhedral an polygon zones are now supported.
Added
- Polygon and polyhedron zones (FEPOLYGON and FEPOLYHEDRON) can be read and
written in PLT and DAT files. They are returned as the new
TecplotPolyZoneReader, a zone class separate from the ordered and FE
classes, with 0-basedface_nodes,face_node_counts,
face_left_elements,face_right_elementsand boundary connection arrays,
returned as stored on disk. Newwrite_poly_zonewriter method (BLOCK
packing only; SZPLT raisesNotImplementedError). Connectivity sharing and
append mode work with poly zones. Every CLI tool that rewrites a file
(teconvert,tecextract,tecfix,tecscale,tecaux,tecmergeand
tecslice) now carries poly zones through, and exits with an error when
asked to write them to SZPLT.tecmerge --merge-gridwrites an identical
poly grid once and shares it across zones (for example transient steps),
matching on a hash of the full face map.tecdumpreports poly counts and
tec2matexports a 1-based face map. Legacy PLT v111 poly zones are
readable.
Fixed
tecslice -tnow writes "anchor" zones for dropped sources to keep the
variables that are shared from them and every shared zone is renumbered.tecextractandtecmergenow remap zones for poly boundary connections.tecmerge --merge-gridno longer drops a zone whose only variables are grid
variables to preserve boundary connections.tecpolybconn142wrapper argument types (boundary connection zones are
INT32 values).- PLT v111 zone header: the extra INT32 follows the zone type.
Full changelog: v0.4.0...v0.4.1
v0.4.0
0.4.0
Python API is now 0-indexed throughout, and TecplotPltReader can read legacy
PLT binary files.
Added
- Read-only support for legacy PLT binary versions v75, v107, and v111 in
TecplotPltReader(and sotecio.open()). The version is detected from the
file's magic string, and the same reader interface is returned for every
version. Older versions carry less information, so some properties are
empty: v75 has no variable sharing, passive variables, face connections,
strand ID or solution time, cell-centered data, or auxiliary data. v75
pyramids and prisms are stored as bricks with repeated nodes and are
returned as read. Writers still produce the current format only, and
tecio.open()raisesValueErrorfor'a'and'a+'on a legacy
file. See the new "Legacy PLT Versions" documentation page for a
version-by-version comparison. .bbinand.bbin8file extensions are now recognized as Tecplot PLT
binary files.tecscalecan now transform multiple variables in a single call.- New
--strand-offsetflag fortecmergeto allow multiple transient data
files to be loaded without automerging overlapping strand IDs (e.g. create
strand IDs 101, 102, 103, ...). - First version of a Tecplot data writer plugin for Paraview,
TecplotTecioWriter.py. - MATLAB function
tecmat2structto reformat the zone structures created by
tec2matinto a struct array of zones with arrays accessible by variable
name.
Changed
- Breaking: the entire Python API is now 0-indexed. Every zone or variable
index accepted or reported by any Python function, class, or method
(container indexing,zone_index,var_index,get_array,
get_zone_auxdata,get_var_auxdata, shared zone and connectivity indices,
and so on) is 0-based. Thetecio.libtecioC wrapper functions keep
Tecplot's 1-based convention, and the reader and writer classes convert
automatically. Existing code that passes or compares indices needs to be
updated, and an index that is off by one often raises no error. - Passive and shared variables are now specified in the writer methods by
naming only those variables. Previously a flag was required for every
variable in the dataset, while data arrays and value locations were only
given for the active ones. Usepassive_vars=["x", "y", "z"]and
var_sharing={"x": 1, "y": 1, "z": 1}(variable name or index mapped to the
shared zone index).
Full changelog: v0.3.3...v0.4.0
v0.3.3
0.3.3
Added
- Added option to automatically share grid when merging with
tecmerge. - Added package level functions to query Tecplot files for zone list, variable
list, etc. without fully paring the file (quick and low memory). - 3rd party plugins using
tecioare now automatically added to the install
sharefolder when installed with pip.
Full changelog: v0.3.2...v0.3.3
v0.3.2
0.3.2
Changed
- Added face neightbor support for PLT and DAT file formats. Hooks
are in place for SZL format, but current version of TecIO library
has a bug that does not read or write face neighbors correctly. - Breaking:
TecplotWriter.write_ijk_zonerenamed to
write_ordered_zone, for symmetry withwrite_fe_zone. - Breaking: Reader container properties renamed for clarity:
.zone→.zonesand.variable→.variables, on every reader and
zone reader class. - Variable names are now supported as an additional input option for CLI tools
wherever previously only variable index was accepted. - Breaking: CLI tool flags are updated for better consistency between tools.
Use-hto see the available flags for each tool. pragma: no coveradded wherever there is environment dependent or
non-converable code execution so coverage report is more accurate.
Fixed
- The number of values in ordered zones without point counts are now inferred
instead of defaulting to one.
Full changelog: v0.3.1...v0.3.2
v0.3.1
0.3.1
Robustness improvementes.
Changed
- Enums (
ZoneType,DataType,FileType,ValueLocation,DataPacking,
FileFormat,FeCellShape,FaceNeighborMode,VarStatus,Boolean,
Debug) now live intecio._constantsand are importable directly from the
top-levelteciopackage (tecio.ZoneType, not just
tecio.libtecio.ZoneType), matching every other public class. Still
re-exported fromtecio.libteciofor backward compatibility. tecio.libtecio's C-library load/bind mechanism is now implemented as
reusable, stateless functions intecio._utils(load_library,bind,
requires_symbol);libtecio.pyitself is reduced to the C function
wrappers and their own state (lib,LIBRARY_LOAD_ERROR,LIBRARY_PATH,
UNAVAILABLE_FUNCTIONS). No behavior change; importingtecio.libtecio
still never raises, even with no Tecplot installation or an older one
missing a newer symbol.bindis now keyword-only at its call sites for readability.
Fixed
TecplotPltWriter.close()andTecplotDatWriter.close()now flush
buffered auxiliary data, matchingTecplotSzlWriter's existing behavior.
Previously, callingadd_auxdataset_dict()/add_auxvar_dict()after the
first zone had already been written silently discarded that data on PLT
and DAT output, no error, nothing written.
Full changelog: v0.3.0...v0.3.1
v0.3.0
0.3.0
Major internal reorganization: reader and writer classes now share a common,
enforced interface across all three formats, and zone readers are split by
topology. tecio.szl, tecio.plt, and tecio.dat no longer exist as public
submodules.
Added
TecplotReader/TecplotWriter— shared abstract base classes defining
the interface every format's reader/writer implements. A subclass cannot be
instantiated unless it implements every required property and method, so the
three formats can no longer drift out of sync with each other.TecplotZoneReader— shared zone interface (title,zone_type,
solution_time,strand_id,variable,auxdata,get_array(), ...),
split into two concrete shapes by topology:TecplotOrderedZoneReader— addsI,J,K,dimensions.TecplotFEZoneReader— addsnode_map,nodes_per_cell,
shared_connectivity, andnum_nodes/num_elements.
TecplotVariableReader,TecplotAuxDataReader— shared variable and
auxiliary-data interfaces, identical for every format. Not split by value
location or zone topology: nodal vs. cell-centered and dataset- vs.
zone-level data only change what one method returns, never which properties
exist.TecplotSzlReader,TecplotPltReader,TecplotDatReader,
TecplotSzlWriter,TecplotPltWriter,TecplotDatWriter— concrete,
per-format classes, imported directly fromtecio.tecio.open()returns
one of these; construct one directly to bypass extension-based dispatch.- Zone, variable, and auxiliary-data reader objects are now immutable,
assigning to any attribute raisesAttributeError. zone_indexis now part of the sharedTecplotZoneReaderinterface on
every format (previously present on some formats' zone objects but not
guaranteed on all three).
Changed
- Breaking: a zone's topology-specific properties now only exist on the
matching subclass.zone.node_map/.shared_connectivity/
.nodes_per_cellraiseAttributeErroron an ordered zone (previously
returnedNone);zone.I/.J/.K/.dimensionsraise
AttributeErroron an FE zone (previously unused placeholder values on some
formats). Useisinstance(zone, TecplotOrderedZoneReader)/
isinstance(zone, TecplotFEZoneReader)to branch on topology. - CLI tools (
tecdump,tecextract,tecfix,tecscale,teconvert,
tec2mat,tecaux,tecmerge,tecslice) updated to use the new classes
internally; command-line interfaces are unchanged.
Fixed
- Auxiliary data added with
add_auxdataset_dict()/add_auxvar_dict()
after a writer was opened with an explicitvariableslist (rather than
left to open lazily on the first zone write) was silently never written to
the file, on all three formats. Auxiliary data is now always flushed before
the first zone regardless of how the writer was opened. - A zone type whose connectivity a format cannot resolve (currently PLT's
FEPOLYGON/FEPOLYHEDRON) re-readnode_mapfrom disk on every access instead
of caching theNoneresult.
Removed
-
Breaking:
tecio.szl,tecio.plt, andtecio.datsubmodules.
szl.Read,szl.Write,plt.Read,plt.Write,dat.Read,dat.Write
no longer exist. UseTecplotSzlReader/TecplotSzlWriter, etc.,
imported directly fromtecio:# Before from tecio.szl import Read r = Read("flow.szplt") # After from tecio import TecplotSzlReader r = TecplotSzlReader("flow.szplt")
tecio.open()is unaffected and remains the recommended entry point for
most use cases.
Full changelog: v0.2.4...v0.3.0
v0.2.4
0.2.4
Performance upgrade.
Added
- Higher performance ascii file read using numpy from file. Way faster for
well-formatted files where data chunk sizes can be estimated from reading
the first 1-2 lines.
Full changelog: v0.2.3...v0.2.4
v0.2.3
0.2.3
Bug fixes and added utilities.
Added
- Paraview plugin to read in all Tecplot file types
- Fixes errors in packaged ParaView Tecplot for zone header fields
SOLUTIONTIMEandSTRANDID. - Provdes
.szpltfile format reading capability in ParaView. - Automatically converts aux data to
vtkFieldData.
- Fixes errors in packaged ParaView Tecplot for zone header fields
Fixed
dat.Readdid not havezone_indexorvar_indexproperties. Fixed to matchszlandpltmodules.
Full changelog: v0.2.2...v0.2.3