RDP Regularizer

Regularizes jittery Redis streams onto a UTC grid, fills gaps by imputation or forecast, and writes a strictly regular output stream.

View the Project on GitHub AIT-RDP/rdp-regularizer

Example configuration

The process loads YAML through pyrdp_commons.cli.setup_app. The CLI default path is config.yml in the working directory (python -m regularizer -c config.yml).

Copy the example below and adjust hosts and credentials. temperature bootstraps from TimescaleDB; setpoint is live-only.

version: 1

logging:
  loggers:
    rdp-regularizer:
      level: INFO
      handlers: ["console"]
      propagate: false

redis:
  host: localhost
  port: 6379
  db: 0

timescale:
  host: localhost
  port: 5432
  db: rdp
  user: rdp
  password: changeme

channels:
  temperature:
    input_stream: measurements.temperature
    output_stream: regularized.temperature
    polling_interval: 1m
    update_interval: 1m
    window: 1h
    jitter_tolerance: 30s
    lag_time: 10s
    offset: 0s
    output_maxlen: 200
    data_provider_name: rdp-regularizer
    imputer: default
    forecaster: default
    history_provider:
      dp_name: temperature
      dp_location_code: building-a
      dp_unit: degC
      dp_data_provider: crawler
      dp_device_id: sensor-01
      init_when_source_available: true
      bootstrap_delay: 10s

  setpoint:
    input_stream: measurements.setpoint
    output_stream: regularized.setpoint
    polling_interval: 1m
    update_interval: 1m
    window: 1h
    jitter_tolerance: 30s
    lag_time: 10s
    offset: 0s