flexmeasures.data.models.reporting

Modules

flexmeasures.data.models.reporting.aggregator

flexmeasures.data.models.reporting.pandas_reporter

flexmeasures.data.models.reporting.profit

Classes

class flexmeasures.data.models.reporting.Reporter(config: dict | None = None, save_config=True, save_parameters=False, **kwargs)

Superclass for all FlexMeasures Reporters.

_compute(check_output_resolution=True, as_job: bool = False, **kwargs) list[dict[str, Any]] | dict[str, Any]

This method triggers the creation of a new report.

The same object can generate multiple reports with different start, end, resolution and belief_time values.

Parameters:
  • check_output_resolution – If True, checks each output for whether the event_resolution matches that of the sensor it is supposed to be recorded on.

  • as_job – If True, a job to compute (and save) the report is queued instead, and a dict like {“job_id”: <uuid>, “n_jobs”: 1} is returned.

_compute_report(**kwargs) list[dict[str, Any]]

Overwrite with the actual computation of your report.

Returns list of dictionaries, for example:
[
{

“sensor”: 501, “data”: <a BeliefsDataFrame>,

},

]