gnome.spills.le

Classes

LEData

A MutableMapping is a generic container for associating

Module Contents

class gnome.spills.le.LEData(name=None, *args, **kwargs)

Bases: collections.abc.MutableMapping, gnome.gnomeobject.AddLogger, dict

A MutableMapping is a generic container for associating key/value pairs.

This class provides concrete generic implementations of all methods except for __getitem__, __setitem__, __delitem__, __iter__, and __len__.

Initialize self. See help(type(self)) for accurate signature.

mass_balance
name = None
rewind()
clear

D.clear() -> None. Remove all items from D.

property num_released

The number of elements currently in the SpillContainer

If SpillContainer is initialized, all data_arrays exist as ndarrays even if no elements are released. So this will always return a valid int >= 0.

prepare_for_model_run(array_types, substance)
initialize_data_arrays()

initialize_data_arrays() is called without input data during rewind and prepare_for_model_run to prepare the buffers and define the data arrays.

extend_data_arrays(num_new_elements)

Adds num_new_elements to the data arrays. Resizes the arrays as necessary. Data arrays are set to their initial_values

Parameters:

num_new_elements (int) – number of particles released