ResultReader
ResultReader
Bases: ABC
Advanced interface for implementing a new recorder-file reader.
Most users should use open_results(), not subclass this interface. A reader supplies a single file/partition's geometry, sample coordinates, and fields. Advertise only implemented capabilities; unsupported operations raise UnsupportedResultOperation by default.
Parameters:
| Name | Type | Description | Default |
|---|---|---|---|
path
|
Union[str, Path]
|
File path stored by the base class. Concrete readers own validation and file handles, and must release resources in close(). |
required |
Note
Indices passed to history/frame methods are zero-based mesh indices, not solver entity tags. Fields and sample coordinates retain file units. Register an implementation with femora.results.register_reader() to use it through open_results(). Context-manager exit calls close().
Attributes
capabilities
abstractmethod
property
Operations supported by this reader.
times
abstractmethod
property
Return recorded times, or None when time was not recorded.
number_of_steps
abstractmethod
property
Return the number of recorded samples independently of time data.
available_point_responses
abstractmethod
property
Return available transient point-response names.
available_cell_responses
abstractmethod
property
Return available transient cell-response names.
Methods:
point_history
Return one point's response over all recorded times.
cell_history
Return one cell's response over all recorded times.
point_frame
Return a point-response field at one recorded step.
cell_frame
Return a cell-response field at one recorded step.