PlatformInfo

class PlatformInfo(*args, **kwargs)

Informations about platform.

No constructor, only static methods are available.

Methods

GetCompilerId()

Accessor to the compiler id.

GetCompilerVersion()

Accessor to the compiler version.

GetDate()

Accessor to the build date.

GetFeatures()

Accessor to the features list.

GetInstallationDirectory()

Accessor to the install prefix.

GetNumericalPrecision()

Accessor to the output numerical precision.

GetRevision()

Accessor to the revision string.

GetSystemName()

Accessor to the system name.

GetSystemProcessor()

Accessor to the system processor.

GetSystemVersion()

Accessor to the system version.

GetVersion()

Accessor to the version string.

HasFeature(feature)

Test a feature's availability.

SetNumericalPrecision(precision)

Accessor to the output numerical precision.

Summary()

Accessor to infos summary.

__init__(*args, **kwargs)
static GetCompilerId()

Accessor to the compiler id.

Returns:
idstr

Compiler id (GNU, MSVC…).

static GetCompilerVersion()

Accessor to the compiler version.

Returns:
versionstr

Compiler version.

static GetDate()

Accessor to the build date.

Returns:
datestr

Build date.

static GetFeatures()

Accessor to the features list.

Returns:
featuresDescription

Features list.

Examples

>>> import openturns as ot
>>> print(ot.PlatformInfo.GetFeatures())
[bonmin,...
static GetInstallationDirectory()

Accessor to the install prefix.

Returns:
prefixstr

Installation prefix.

static GetNumericalPrecision()

Accessor to the output numerical precision.

Returns:
precisionint

String output numerical precision.

static GetRevision()

Accessor to the revision string.

Returns:
revisionstr

Git revision.

static GetSystemName()

Accessor to the system name.

Returns:
namestr

System name.

static GetSystemProcessor()

Accessor to the system processor.

Returns:
processorstr

System processor.

static GetSystemVersion()

Accessor to the system version.

Returns:
versionstr

System version.

static GetVersion()

Accessor to the version string.

Returns:
versionstr

Version string.

static HasFeature(feature)

Test a feature’s availability.

Parameters:
featurestr

The desired feature, often associated to a software dependency, Call GetFeatures() for the possible feature values.

Returns:
has_featurebool

Whether the designated feature is available.

Examples

>>> import openturns as ot
>>> have_xml_support = ot.PlatformInfo.HasFeature('libxml2')
static SetNumericalPrecision(precision)

Accessor to the output numerical precision.

Parameters:
precisionint

String output numerical precision.

static Summary()

Accessor to infos summary.

Returns:
summarystr

Summary of version, compiler, features…