pymoose.load
pymoose.load#
- pymoose.load(key, query='', dtype=None, vtype=None, placement=None)[source]#
Load a value from placement storage.
The underlying key-value store implementation is runtime-specific. Generally, assume that each HostPlacement can be using a different storage implementation in its Moose worker/executor.
- Parameters
key – A string or Moose String corresponding to the value that should be loaded.
query – An optional query string/String to provide to executor storage. Most common storage implementations ignore this.
dtype – If value should be loaded as a tensor, the DType to coerce the tensor to. If None, inferred from the value’s numpy dtype.
vtype – The Moose type to coerce the loaded value into. If None, will be traced as
UnknownTypeand the compiler will attempt to fill it in during its initial Typing pass.placement – An optional
Placementto pin this operation to.
- Returns
The loaded value, as provided by the worker backing the HostPlacement.