Skip to content

Latest commit

 

History

7 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Reduce Property

Apply common reduction operations to properties in the DataCollection

Description

Apply one of the following reduction operations to a selected property. If the property has multiple components, e.g. position, the reduction operation is applied for each component.

Operations:

- Mean
- Median
- Standard Deviation
- Variance
- Minimum
- Maximum
- Sum
- Non-zero

Parameters

GUI name Python name Description Default Value
Container input_container Container from which a property is selected.
Property input_property Property to which the reduction operation will be applied.
Operation operation Reduction operation to apply to the selected property. "Mean"
Reduce only selected elements only_selected Apply reduction operation only to selected entries in the property array. Requires the "Selection" property to be present in the container. False

The output is stored in a global attribute under the <container>_<property>_<operation> key.

Example

Example_01

# Reduce Property:
pipeline.modifiers.append(
    ReduceProperty(
        input_container=DataObject.Ref(Particles, "particles"),
        input_property="Velocity",
    )
)

Installation

Technical information / dependencies

  • Tested on OVITO version 3.11.0

Contact

About

Apply reduction operations to OVITO properties

Topics

Resources

Stars

1 star

Watchers

1 watching

Forks

Contributors

Languages