fluiddyn.calcul.setofvariables

Variable container (fluiddyn.calcul.setofvariables)

Provides:

class fluiddyn.calcul.setofvariables.SetOfVariables(input_array=None, keys=None, shape_variable=None, like=None, value=None, info=None, dtype=None, **kwargs)[source]

Bases: ndarray

np.ndarray containing the variables.

Parameters:
input_arraynumpy.ndarray, optional

Input array, default to None.

keysIterable, optional

Keys corresponding to the variables, default to None.

shape_variableIterable, optional

Shape of an array containing one variable, default to None.

likeSetOfVariables, optional

Model for creating the new SetOfVariables, default to None.

valueNumber, optional

For initialization of the new SetOfVariables, default to None.

infostr, optional

Description, default to None.

dtypenumpy.dtype, optional

see numpy.ndarray help.

set_var(arg, value)[source]

Set a variable.

get_var(arg)[source]

Get a variable as a np.array.

initialize(value=0)[source]

Initialize as a constant array.

Classes

SetOfVariables([input_array, keys, ...])

np.ndarray containing the variables.