fluent_version#
Provides a module to get Fluent version.
Exceptions:
|
Raised when Ansys version is not found. |
Raised when a comparison can't be completed. |
Classes:
|
An enumeration over supported Fluent versions. |
|
A set of Fluent versions defined by a predicate. |
Functions:
Create a FluentVersionSet that includes all supported Fluent versions. |
|
|
Create a FluentVersionSet that includes all versions between the specified start (inclusive) and end (exclusive) versions. |
|
Create a FluentVersionSet that includes all versions except the specified version. |
|
Get Fluent version. |
|
Get Fluent version for file name. |
|
Create a FluentVersionSet that includes only the specified version. |
|
Create a FluentVersionSet that includes all versions since the specified version. |
|
Create a FluentVersionSet that includes all versions until the specified version. |
- exception ansys.fluent.core.utils.fluent_version.AnsysVersionNotFound(version)#
Bases:
RuntimeErrorRaised when Ansys version is not found.
Methods:
__init__(version)Initialize VersionNotFound.
- exception ansys.fluent.core.utils.fluent_version.ComparisonError#
Bases:
RuntimeErrorRaised when a comparison can’t be completed.
Methods:
__init__()Initialize ComparisonError.
- __init__()#
Initialize ComparisonError.
- class ansys.fluent.core.utils.fluent_version.FluentVersion(value, names=None, *, module=None, qualname=None, type=None, start=1, boundary=None)#
Bases:
EnumAn enumeration over supported Fluent versions.
Examples
FluentVersion(“23.2.0”) == FluentVersion.v232
FluentVersion.v232.number == 232
FluentVersion.v232.awp_var == ‘AWP_ROOT232’
Attributes:
Get the Fluent version in AWP environment variable format.
Get the Fluent version as a Docker image tag.
Get the Fluent version as a plain integer.
Methods:
Return the version member of the current development version.
Return the version member of the current release.
Get the path for the Fluent executable file.
Return the version member corresponding to the most recent, available ANSYS installation.
- property awp_var#
Get the Fluent version in AWP environment variable format.
- classmethod current_dev()#
Return the version member of the current development version.
- Returns:
FluentVersionFluentVersion member corresponding to the latest development version.
- classmethod current_release()#
Return the version member of the current release.
- Returns:
FluentVersionFluentVersion member corresponding to the latest release.
- property docker_image_tag#
Get the Fluent version as a Docker image tag.
- get_fluent_exe_path()#
Get the path for the Fluent executable file.
- Returns:
PathFluent executable path.
- classmethod get_latest_installed()#
Return the version member corresponding to the most recent, available ANSYS installation.
- Returns:
FluentVersionFluentVersion member corresponding to the newest Fluent version.
- Raises:
FileNotFoundErrorIf an Ansys version cannot be found.
- property number#
Get the Fluent version as a plain integer.
- v222 = '22.2.0'#
- v231 = '23.1.0'#
- v232 = '23.2.0'#
- v241 = '24.1.0'#
- v242 = '24.2.0'#
- v251 = '25.1.0'#
- v252 = '25.2.0'#
- v261 = '26.1.0'#
- class ansys.fluent.core.utils.fluent_version.FluentVersionSet(predicate)#
Bases:
Set[FluentVersion]A set of Fluent versions defined by a predicate.
Methods:
__init__(predicate)Initialize the FluentVersionSet with a predicate.
- __init__(predicate)#
Initialize the FluentVersionSet with a predicate.
- ansys.fluent.core.utils.fluent_version.all_versions()#
Create a FluentVersionSet that includes all supported Fluent versions.
- Returns:
FluentVersionSetA set containing all Fluent versions.
- ansys.fluent.core.utils.fluent_version.between(start, end)#
Create a FluentVersionSet that includes all versions between the specified start (inclusive) and end (exclusive) versions.
- Parameters:
- start
FluentVersion The starting version of the range, inclusive.
- end
FluentVersion The ending version of the range, exclusive.
- start
- Returns:
- ansys.fluent.core.utils.fluent_version.except_for(version)#
Create a FluentVersionSet that includes all versions except the specified version.
- Parameters:
- version
FluentVersion The version to exclude from the set.
- version
- Returns:
- ansys.fluent.core.utils.fluent_version.get_version(session=None)#
Get Fluent version.
- ansys.fluent.core.utils.fluent_version.get_version_for_file_name(version=None, session=None)#
Get Fluent version for file name.
- ansys.fluent.core.utils.fluent_version.only_at(version)#
Create a FluentVersionSet that includes only the specified version.
- Parameters:
- version
FluentVersion The version to include in the set.
- version
- Returns:
- ansys.fluent.core.utils.fluent_version.since(version)#
Create a FluentVersionSet that includes all versions since the specified version.
- Parameters:
- version
FluentVersion The version since which the set should include versions.
- version
- Returns:
- ansys.fluent.core.utils.fluent_version.until(version)#
Create a FluentVersionSet that includes all versions until the specified version.
- Parameters:
- version
FluentVersion The version until which the set should include versions.
- version
- Returns: