pytuflow.INFO#
- class INFO(fpath)#
Bases:
TimeSeriesClass for reading TUFLOW info time series results (
.info). These are text files with a.infoextension (typically found in the 1D output folder and ending with_1d.infoand not.2dm.info) that are output by the 2013 TUFLOW release. The format is similar to the TPC format, however does not include2d_poor Reporting Location (0d_rl) results.The
INFOclass will only load basic properties on initialisation. These are typically properties that are easy to obtain from the file without having to load any of the time-series results. Once a method requiring more detailed information is called, the full results will be loaded. This makes theINFOclass very cheap to initialise.- Parameters:
fpath (PathLike) – The path to the output (.info) file.
- Raises:
ResultTypeError – Raises
pytuflow.results.ResultTypeErrorif the file does not look like a time seriesINFOfile.
Examples
Load a
.infofile:>>> from pytuflow import INFO >>> res = INFO('path/to/file.info')
Querying all the available data types:
>>> res.data_types() ['water level', 'flow', 'velocity']
Querying all the available 1D channel IDs
>>> res.ids('channel') ['FC01.1_R', 'FC01.2_R', 'FC04.1_C']
Extracting the time-series information for a given channel and data type:
>>> res.time_series('FC01.1_R', 'flow') time channel/flow/FC01.1_R 0.000000 0.000 0.016667 0.000 0.033333 0.000 0.050000 0.000 0.066667 0.000 ... ... 2.933333 3.806 2.950000 3.600 2.966667 3.400 2.983334 3.214 3.000000 3.038
For more examples, see the documentation for the individual methods.
- __init__(fpath)#
- Parameters:
fpath (Path | str)
Methods
Not supported for
INFOresults.Returns all the available data types (result types) for the given filter.
Returns all the available IDs for the given filter.
Returns a DataFrame containing the maximum values for the given data types.
Not supported for
INFOresults.Returns a long plot for the given location and data types at the given time.
Returns a time-series DataFrame for the given location(s) and data type(s).
Returns all the available times for the given filter.
Attributes
The path to the source output file.
The unit system used in the output file.
Information on all 1D output objects.
Number of nodes
Number of channels
The result name
The reference time for the output