AvailableResult#

class ansys.dpf.core.available_result.AvailableResult(availableresult)#

Represents a result that can be requested via an operator.

Parameters:

availableresult (available_result_pb2.AvailableResult message.)

Examples

Explore an available result from the model.

>>> from ansys.dpf import core as dpf
>>> from ansys.dpf.core import examples
>>> transient = examples.download_transient_result()
>>> model = dpf.Model(transient)
>>> result_info = model.metadata.result_info
>>> res = result_info.available_results[0]
>>> res.name
'displacement'
>>> res.homogeneity
'length'
>>> res.dimensionality
'vector'

Create the operator of the given available result.

>>> disp = model.results.displacement()

Overview#

name

Result operator.

n_components

Number of components of the result.

dimensionality

Dimensionality nature of the result, such as a vector, scalar, or tensor.

homogeneity

Homogeneity of the result.

unit

Unit of the result.

operator_name

Name of the corresponding operator.

sub_results

List of the subresult.

native_location

Native location of the result.

native_scoping_location

Native scoping location of the result.

physical_name

Name of the result with spaces.

qualifiers

Returns the list of qualifiers (equivalent to label spaces) available for a given Result.

qualifier_labels

Returns a dictionary of available labels for each available qualifier.

qualifier_combinations

Returns the list of valid qualifier combinations for this result.

__str__

Construct an informal string representation of available result.

__repr__

Construct a formal string representation of available result.

Import detail#

from ansys.dpf.core.available_result import AvailableResult

Property detail#

property AvailableResult.name#

Result operator.

property AvailableResult.n_components#

Number of components of the result.

property AvailableResult.dimensionality#

Dimensionality nature of the result, such as a vector, scalar, or tensor.

property AvailableResult.homogeneity#

Homogeneity of the result.

property AvailableResult.unit#

Unit of the result.

property AvailableResult.operator_name#

Name of the corresponding operator.

property AvailableResult.sub_results#

List of the subresult.

property AvailableResult.native_location#

Native location of the result.

property AvailableResult.native_scoping_location#

Native scoping location of the result.

property AvailableResult.physical_name: str#

Name of the result with spaces.

property AvailableResult.qualifiers: list#

Returns the list of qualifiers (equivalent to label spaces) available for a given Result.

These qualifiers can then be used to request the result on specified locations/properties.

property AvailableResult.qualifier_labels: dict#

Returns a dictionary of available labels for each available qualifier.

property AvailableResult.qualifier_combinations: List[dict]#

Returns the list of valid qualifier combinations for this result.

Each combination is a dictionary which can be used for a result request.

Method detail#

AvailableResult.__str__()#

Construct an informal string representation of available result.

Returns:

Informal string representation of available result.

Return type:

str

AvailableResult.__repr__()#

Construct a formal string representation of available result.

Returns:

Formal string representation of available result.

Return type:

str