- class rxsci.state.MemoryStore(name=None, data_type='obj', default_value=None)¶
A Memory state store
Statefull MuxObervable operators need to maintain one state per key. Keys have to be indexables, i.e. index into a table/array. This allows fast lookup (compared to hash tables). As statefull operators are chained in a graph, each one builds its own key scheme. In order to unroll these key schemes, the key of a MuxObservable item is a nested tuple of keys:
(k4, (k3, (k2, (k1, (k0)))))
This class helps in managing muxed items, and store a state for each topmost level of the key (i.e. key).
Use a memory state store to manage stateful operations
pipeline – A computation graph where the state is stored in memory.
- rxsci.state.with_store(store, pipeline)¶
Use a state store to manage stateful operations
store – A Store object.
pipeline – A computation graph where state is stored on store.