ansys.pyensight.core.libuserd#

The libuserd module allows PyEnSight to directly access EnSight user-defined readers (USERD). Any file format for which EnSight uses a USERD interface can be read using this API

Examples#

>>> from ansys.pyensight.core import libuserd
>>> userd = libuserd.LibUserd()
>>> userd.initialize()
>>> print(userd.library_version())
>>> datafile = "/example/data/CFX/Axial_001.res"
>>> readers = userd.query_format(datafile)
>>> data = readers[0].read_dataset(datafile)
>>> print(data.parts())
>>> print(data.variables())
>>> userd.shutdown()

Classes

ElementType(value)

An enumeration.

ErrorCodes(value)

An enumeration.

LibUserd([ansys_installation, use_docker, ...])

LibUserd is the primary interface to the USERD library.

Part(userd, pb)

This class represents the EnSight notion of a part.

PartHints(value)

An enumeration.

Query(userd, pb)

The class represents a reader "query" instance.

Reader(userd, pb)

This class represents is an instance of a user-defined reader that is actively reading a dataset.

ReaderInfo(userd, pb)

This class represents an available reader, before it has been instantiated.

Variable(userd, pb)

The class represents a reader "variable" instance.

VariableLocation(value)

An enumeration.

VariableType(value)

An enumeration.

Exceptions

LibUserdError(msg)

This class is an exception object raised from the libuserd library itself (not the gRPC remote interface).