Skip to content
weSkelDOCUMENTATION
Documentation/API reference/PlusMinusAverage

PlusMinusAverage

Sum, difference and average of scalar or vector arrays.

ClassAPI 2.0MATHS
objectNodeDGNodePlusMinusAverage
from weSkel.src.core.node.dg.plus_minus_average.lib import PlusMinusAverage

Run in Maya or an initialized mayapy process. Import om only if your script uses OpenMaya types.

Item Value
Classe PlusMinusAverage
Module weSkel.src.core.node.dg.plus_minus_average.lib
Maya type plusMinusAverage
Direct parent DGNode
Inventory Members defined or overridden here; inherited members are grouped by parent in each section.

Signature : PlusMinusAverage(node) → PlusMinusAverage.

Parameter Accepted type Default
node Union[str, om.MObject, om.MObjectHandle, om.MFnDependencyNode] Required

Wraps an existing node or stages a wrapper for an absent name; does not create the node. Call create() separately. An incompatible object or type can raise TypeError. Shared identity can return an already registered compatible wrapper.

Python properties defined or overridden here. R: read-only; R/W: a setter exists, subject to the member notes. om.* types belong to maya.api.OpenMaya.

No new Python property; see inherited members and specs below.

Properties inherited from DGNode15
Property Return type Access Description
dep_fn om.MFnDependencyNode R Live function set; unattached object when the node is missing.
uuid str | None R Live UUID, or the last staged value if still available.
name str | None R/W Live name, otherwise staged name.
absolute_name str | None R Absolute namespace name from MFnDependencyNode.absoluteName(); None without a node.
stripped_name str | None R/W Name without its namespace, or None when unnamed.
namespace str | None R/W Normalized namespace such as a:b; None at the root.
plugs Plugs | None R Live node plug manager; None otherwise.
is_valid_dep_fn bool R Function-set compatibility with the current MObject.
is_default_node bool R Whether this is a Maya default node; False without a node.
is_from_referenced_file bool R Whether the node comes from a referenced file; False without a node.
is_locked bool R/W Node lock, separate from plug locks.
is_shared bool R Shared state reported by Maya; False without a node.
plugin_name str | None R Associated Maya plugin name, possibly an empty string; None without a node.
affect_animation bool R Result of MFnDependencyNode.affectsAnimation(); False without a node.
type str | None R/W Live native type or staged type.
Properties inherited from Node10
Property Return type Access Description
mobject om.MObject R/W Live Maya object, or a null object.
mobject_handle om.MObjectHandle R/W Handle associated with the node.
api_type int | None R Maya API type identifier.
api_type_str str R API type name, for example "kTime".
exists bool R The wrapper currently has a live node.
is_null bool R The returned Maya object is null.
is_alive bool R The object exists with a valid, live handle.
is_valid_handle bool R Validity of the stored handle.
is_dag_node bool R Compatibility with om.MFn.kDagNode.
hash_code int R Maya handle hash.

Defaults and flags below are spec declarations, not guaranteed live values. A descriptor can return a proxy: .value reads its value; .plug accesses the Plug. Proxy names describe results, not private classes to import. Observed types come from a test fixture; disconnected geometry inputs may notably return None.

For writes where failure must be checked, use the Plug explicitly and verify live state. Descriptor setters do not propagate every native failure.

Property Maya plug Returns
input_1d input1D TypedArrayProxy
input_2d input2D _DynNumericArrayProxy
input_2d_x input2D[].input2Dx IndexedPathProxy
input_2d_y input2D[].input2Dy IndexedPathProxy
input_3d input3D _DynNumericArrayProxy
input_3d_x input3D[].input3Dx IndexedPathProxy
input_3d_y input3D[].input3Dy IndexedPathProxy
input_3d_z input3D[].input3Dz IndexedPathProxy
operation operation _ValuePlugProxy · .value: int
output_1d output1D _ValuePlugProxy · .value: float
output_2d output2D _ValuePlugProxy · .value: tuple
output_2d_x output2D.output2Dx _ValuePlugProxy · .value: float
output_2d_y output2D.output2Dy _ValuePlugProxy · .value: float
output_3d output3D _ValuePlugProxy · .value: tuple
output_3d_x output3D.output3Dx _ValuePlugProxy · .value: float
output_3d_y output3D.output3Dy _ValuePlugProxy · .value: float
output_3d_z output3D.output3Dz _ValuePlugProxy · .value: float

node.input_1dNative spec

Access to native plug input1D.

Item Type / behavior
Maya path input1D
Property return TypedArrayProxy
Declared kind array:numeric:float
Declared default ()
Flags array, input, connectable, stored, keyable
Underlying plug node.input_1d.plug

node.input_2dNative spec

Access to native plug input2D.

Item Type / behavior
Maya path input2D
Property return _DynNumericArrayProxy
Declared kind array:numeric:float2
Declared default ()
Flags array, input, connectable, stored, keyable
Underlying plug node.input_2d.plug

node.input_2d_xNative spec

Access to native plug input2D[].input2Dx.

Item Type / behavior
Maya path input2D[].input2Dx
Property return IndexedPathProxy
Declared kind numeric:float
Declared default 0.0
Flags input, connectable, stored, keyable
Verified explicit path · Plug node.plugs["input2D"][i1]["input2Dx"]

Observed limitation on the tested fixture: AttributeError: Child 'input2Dx' not found under 'api_PlusMinusAverage.input2D[0]'. Indices are Maya logical indices; choose existing or intended elements.

node.input_2d_yNative spec

Access to native plug input2D[].input2Dy.

Item Type / behavior
Maya path input2D[].input2Dy
Property return IndexedPathProxy
Declared kind numeric:float
Declared default 0.0
Flags input, connectable, stored, keyable
Verified explicit path · Plug node.plugs["input2D"][i1]["input2Dy"]

Observed limitation on the tested fixture: AttributeError: Child 'input2Dy' not found under 'api_PlusMinusAverage.input2D[0]'. Indices are Maya logical indices; choose existing or intended elements.

node.input_3dNative spec

Access to native plug input3D.

Item Type / behavior
Maya path input3D
Property return _DynNumericArrayProxy
Declared kind array:numeric:float3
Declared default ()
Flags array, input, connectable, stored, keyable
Underlying plug node.input_3d.plug

node.input_3d_xNative spec

Access to native plug input3D[].input3Dx.

Item Type / behavior
Maya path input3D[].input3Dx
Property return IndexedPathProxy
Declared kind numeric:float
Declared default 0.0
Flags input, connectable, stored, keyable
Verified explicit path · Plug node.plugs["input3D"][i1]["input3Dx"]

Observed limitation on the tested fixture: AttributeError: Child 'input3Dx' not found under 'api_PlusMinusAverage.input3D[0]'. Indices are Maya logical indices; choose existing or intended elements.

node.input_3d_yNative spec

Access to native plug input3D[].input3Dy.

Item Type / behavior
Maya path input3D[].input3Dy
Property return IndexedPathProxy
Declared kind numeric:float
Declared default 0.0
Flags input, connectable, stored, keyable
Verified explicit path · Plug node.plugs["input3D"][i1]["input3Dy"]

Observed limitation on the tested fixture: AttributeError: Child 'input3Dy' not found under 'api_PlusMinusAverage.input3D[0]'. Indices are Maya logical indices; choose existing or intended elements.

node.input_3d_zNative spec

Access to native plug input3D[].input3Dz.

Item Type / behavior
Maya path input3D[].input3Dz
Property return IndexedPathProxy
Declared kind numeric:float
Declared default 0.0
Flags input, connectable, stored, keyable
Verified explicit path · Plug node.plugs["input3D"][i1]["input3Dz"]

Observed limitation on the tested fixture: AttributeError: Child 'input3Dz' not found under 'api_PlusMinusAverage.input3D[0]'. Indices are Maya logical indices; choose existing or intended elements.

node.operationNative spec

Access to native plug operation.

Item Type / behavior
Maya path operation
Property return _ValuePlugProxy · .value: int
Declared kind enum
Declared default 1
Flags input, output, connectable, stored
Native enum values 0 = No operation, 1 = Sum, 2 = Subtract, 3 = Average
Read node.operation.value
Descriptor assignment node.operation = value

node.output_1dNative spec

Access to native plug output1D.

Item Type / behavior
Maya path output1D
Property return _ValuePlugProxy · .value: float
Declared kind numeric:float
Declared default 0.0
Flags output, connectable
Read node.output_1d.value

node.output_2dNative spec

Access to native plug output2D.

Item Type / behavior
Maya path output2D
Property return _ValuePlugProxy · .value: tuple
Declared kind float2
Declared default ()
Flags output, connectable
Read node.output_2d.value

node.output_2d_xNative spec

Access to native plug output2D.output2Dx.

Item Type / behavior
Maya path output2D.output2Dx
Property return _ValuePlugProxy · .value: float
Declared kind numeric:float
Declared default 0.0
Flags output, connectable
Read node.output_2d_x.value

node.output_2d_yNative spec

Access to native plug output2D.output2Dy.

Item Type / behavior
Maya path output2D.output2Dy
Property return _ValuePlugProxy · .value: float
Declared kind numeric:float
Declared default 0.0
Flags output, connectable
Read node.output_2d_y.value

node.output_3dNative spec

Access to native plug output3D.

Item Type / behavior
Maya path output3D
Property return _ValuePlugProxy · .value: tuple
Declared kind float3
Declared default ()
Flags output, connectable
Read node.output_3d.value

node.output_3d_xNative spec

Access to native plug output3D.output3Dx.

Item Type / behavior
Maya path output3D.output3Dx
Property return _ValuePlugProxy · .value: float
Declared kind numeric:float
Declared default 0.0
Flags output, connectable
Read node.output_3d_x.value

node.output_3d_yNative spec

Access to native plug output3D.output3Dy.

Item Type / behavior
Maya path output3D.output3Dy
Property return _ValuePlugProxy · .value: float
Declared kind numeric:float
Declared default 0.0
Flags output, connectable
Read node.output_3d_y.value

node.output_3d_zNative spec

Access to native plug output3D.output3Dz.

Item Type / behavior
Maya path output3D.output3Dz
Property return _ValuePlugProxy · .value: float
Declared kind numeric:float
Declared default 0.0
Flags output, connectable
Read node.output_3d_z.value
Specs inherited from DGNode6
Property Maya plug Returns Description
message message None Node message plug; used for connections, with no numeric value.
frozen frozen _ValuePlugProxy · .value: bool Native evaluation freeze state.
is_historically_interesting isHistoricallyInteresting _ValuePlugProxy · .value: int Node interest level in Maya history.
bin_membership binMembership _ValuePlugProxy · .value: str Maya bin membership.
caching_enabled caching _ValuePlugProxy · .value: bool Native node caching switch.
caching_node_state nodeState _ValuePlugProxy · .value: int Native nodeState evaluation state.

No additional public method; inherited methods remain available.

Methods inherited from DGNode7
Method Returns Description
create None Creates a missing node; does nothing if it already exists.
delete None Disconnects live connections, detaches the wrapper and deletes the node.
snapshot DGSnapshot Captures and stores an identity and spec-driven SVD dictionary.
snapshot_svd SVDSnapshot Captures Source / Value / Destinations for the requested list.
svd SVDView Returns a read-only live view of source, value and destinations; it is not a frozen capture.
finalize None Applies all sources, then undriven values, then destinations; enabled FSET dispatch follows.
clear_attr_cache None Clears this instance attribute cache; does not delete nodes or clear the global wrapper registry.
Methods inherited from Node2
Method Returns Description
has_fn(fn_type) bool Test compatibility with a Maya function set.
clear_node_registry() None Detach registered wrappers and clear their shared registry.
Attribute Value / composition
NODE_TYPE 'plusMinusAverage'
SPEC_LAYERS get_dg_specs_all, get_plus_minus_average_specs_all

NODE_REGISTRY and other class attributes not overridden here remain inherited. Exported Snapshot types describe dictionaries; use node.snapshot() to capture state.

Point Behavior
Identity A node recreated under the same name is a new Maya object.
Creation and geometry The constructor creates nothing; call create() before live operations.
Capture Snapshots can contain Maya objects; do not assume JSON-ready data or complete geometry reconstruction.

Self-contained Maya Python Script Editor example. In mayapy, initialize maya.standalone before this block. The demonstration creates its own nodes and removes them in finally.

from uuid import uuid4
from weSkel.src.core.node.dg.plus_minus_average.lib import PlusMinusAverage
node = PlusMinusAverage("api_plus_minus_average_" + uuid4().hex[:8])
try:
node.create()
node.operation = 1
node.plugs["input1D"][0].value = 2.0
node.plugs["input1D"][1].value = 3.0
assert abs(node.output_1d.value - 5.0) < 1e-6
print("PlusMinusAverage: native evaluation OK")
finally:
node.delete(snapshot=False)

Expected result : PlusMinusAverage: native evaluation OK.

SDK checkpoint 87c3486. Member inventory checked against loaded classes in Maya 2025.3 and 2026.3; reads and compatibility are specified in the member cards. Example run in both versions, including explicitly documented expected failures. The example does not cover every method. Listed limitations remain in source; these checks do not validate the compiled package.