Mondaic

salvus.flow.collections.event_data_collection_proxy

salvus.flow.collections.event_data_collection_proxy salvus flow collections event_data_collection_proxy

EventData collection object.

Classes

EventDataCollectionProxy

class EventDataCollectionProxy(builtins.object):
    def __init__(
        self, proxy_type: str, config: dict, proxy_import: str | None = None
    ): ...

A data proxy describes how to get data from external sources. This could be external files or a web service or something else completely.

Parameters
  • proxy_type str — The name of the proxy as a string.
  • config dict — The proxy configuration.
  • proxy_import str | None — External proxies might require to be imported. Optionally specify the to-be-imported module here.
Methods
read()
def read(filename: pathlib.Path | str) -> EventDataCollectionProxy: ...

Read an event data collection proxy.

Parameters
  • filename pathlib.Path | str — Path to the file on disk.
Returns EventDataCollectionProxy
get_event_data()
def get_event_data(self, event: Event) -> EventData: ...

Load the data for a given event.

Parameters
  • event Event — The event to load the data for.
Returns EventData
write()
def write(self, filename: pathlib.Path | str) -> None: ...

Write the proxy configuration to a file.

Parameters
  • filename pathlib.Path | str — Output filename.
Returns None