Continuous Deep Learning for Smarter Energy Igor Gotlibovych - - PowerPoint PPT Presentation

continuous deep learning for smarter energy
SMART_READER_LITE
LIVE PREVIEW

Continuous Deep Learning for Smarter Energy Igor Gotlibovych - - PowerPoint PPT Presentation

Continuous Deep Learning for Smarter Energy Igor Gotlibovych Javier Asensio-Cubero Jaye Cribb Constantin Octopus The Energy is Getting Smarter Traditional grid: Smart grid: - predictable generation - distributed renewable generation -


slide-1
SLIDE 1

Continuous Deep Learning for Smarter Energy

Igor Gotlibovych Javier Asensio-Cubero Jaye Cribb Constantin Octopus

slide-2
SLIDE 2

The Energy is Getting Smarter

Traditional grid:

  • predictable generation
  • static consumption
  • fixed tariffs
  • timescale of years/months

Smart grid:

  • distributed renewable generation
  • dynamic consumption behaviour
  • smart meters
  • agile tariffs
  • API integration
  • timescale of hours/minutes

2

slide-3
SLIDE 3

A Brief History of Octopus Energy & AI

  • founded in 2015
  • Apr 2017: 100% renewable sources
  • Feb 2018: UK’s first Agile tariff
  • Jul 2018: +100k IRESA customers
  • Nov 2018: acquired ML team from Usio
  • Jan 2019: 500k customers
  • ~600k customers; ~50k smart meters
  • 20+ developers
  • 6+ Data Scientists/ML Engineers

Machine Learning at Octopus:

  • Time Series Analysis & Forecasting:

○ household consumption ○ response to agile tariffs ○ commercial sites ○ PV generation ○ Customer communications: calls/emails

  • NLP
  • Control theory/RL

○ Optimizing PV/battery/EV utilization

  • Growing ETL/Deep Learning infrastructure

3

slide-4
SLIDE 4

Smart tariffs and Behavioural Response

Agile tariff response: early trial Agile tariff response analysis: regression + SHAP

4

slide-5
SLIDE 5

Time Series Forecasting with Deep Learning

“What will the half-hourly consumption be for customer #500001 at 2019-02-29 12:00?” features X prediction y 500001 2019 2 29 12 2.3

  • Why not iterative auto-regressive model?

○ Deep learning is powerful enough to turn this: f(f(f(f(...f(X)...)))) [n times] into this: g(X, n)

5

slide-6
SLIDE 6

6

slide-7
SLIDE 7
  • Keep continous features continuous
  • Better still, use periodic encoding

Feature Engineering - Datetime

Jan-31 12:00 0.084 0.5

7

slide-8
SLIDE 8

Feature Engineering - IDs

  • You have a categorical feature
  • You decide to use one-hot encoding
  • Now you have 500k+ features!

500001 ... 1

8

slide-9
SLIDE 9

What we really want to know

#500001 What time do they come home? Do they have electric heating? Do they work weekends? ... m features

9

slide-10
SLIDE 10

Embeddings: the MovieLens Rating Example

10

slide-11
SLIDE 11

Putting it Together

11

slide-12
SLIDE 12

What do Embeddings Learn?

Some things we can’t predict: CTO decides to eat out Portfolio Individual

12

slide-13
SLIDE 13

Model Life-cycle & Continuous Training

time

13

slide-14
SLIDE 14

Continuous deployment, training, and usage.

  • Like cron on steroids: Flexible way to schedule tasks, rerun them, adds

visibility…

○ Written in python. ○ Rather a monolithic approach: code base sharing for the tasks.

slide-15
SLIDE 15

Heterogeneous architecture

slide-16
SLIDE 16

Final approach

  • Dockerized workers

○ Decoupling airflow of dependencies and scheduling. ○ Decoupling airflow from credentials management.

  • AWS autoscaling

○ Turning on and off GPUs on demand.

  • More maintainable codebase.

○ Based on command line scripts. ○ Highly testable and easy to isolate. ○ Airflow dags relegated to a glorified configuration file.

slide-17
SLIDE 17

Lessons Learned

  • Avoid iterative forecasting - use features instead
  • Two ways to learn latent features

○ Embeddings: learn features during backprop ○ Encoders: trained to extract features in forward pass (not covered)

  • Encapsulate feature generation inside your model

○ simpler versioning and deployment ○ simplifies replacing hand-engineered features with end-to-end ML models

  • Build reusable ML code

○ Grow your toolkit ○ Listen to ML Engineers when they tell you to write tests

  • Automate every part of the model lifecycle (Airflow, Kubernetes, ASGs, …)

17

slide-18
SLIDE 18

Thanks!

igor [at] octopus.energy https://ig248.gitlab.io/ @igorgotlibovych javier.asensio [at] octopus.energy Should Data Scientists write Unit Tests? Switch to Octopus Energy here: https://share.octopus.energy/mist-rain-538 Switch to Octopus Energy here: https://share.octopus.energy/sand-fawn-149 always! maybe?

18