Treatments

The class Treatment is a proxy class for real treatments. A Treatment implements a high-level processing procedure. Only one method execute() is to be used.

For instance, the following statements show how to duplicate a mesh.

>>> import antares
>>> dup = antares.Treatment('duplication')
>>> # in interactive mode, this prints the keys that can be set and
>>> # their default values (if any).
>>> print(dup)
List of keys (default value)
    - base
    - vectors ([])
    - coordinates (['x', 'y', 'z'])
    - nb_duplication (in_attr)
    - pitch (in_attr)
>>> # set the different keys
>>> dup['base'] = base
>>> dup['nb_duplication'] = 12
>>> dup['pitch'] = 2 * 3.14157 / 10
>>> result = dup.execute()

Several treatments are available. They are the real subjects of the proxy class.

Some implementations include a minimum set of functionalities, such as a wrapping of VTK functions, to deliver results. Some other are more complex, and use other treatments for example. You may have a look at them if you need to buid your own treatment or an application script.

Boundary Layer

Harmonic Balance/Time Spectral Method

Visualization

Note

Some treatments can use attrs from antares API instead of input keys. If so, the argument can use in_attr is set to ‘yes’ in the key documentation.