Code Monkey home page Code Monkey logo

battery-fast-charging-optimization's Introduction

Closed-loop optimization of fast-charging protocols for batteries with machine learning

This repository contains much of the data, code, and visualizations associated with the paper:

Closed-loop optimization of fast-charging protocols for batteries with machine learning
Peter Attia*, Aditya Grover*, Norman Jin, Kristen Severson, Todor Markov, Yang-Hung Liao, Michael Chen, Bryan Cheong, Nicholas Perkins, Zi Yang, Patrick Herring, Muratahan Aykol, Stephen Harris, Richard Braatz, Stefano Ermon, William Chueh
Nature, 2020

* equal contribution

The codebase is implemented in Python 3.7.

Note that we use the terms "policy" and "protocol" interchangeably in this code.

Examples

Below we provide some example commands to run the key source files.

  1. Defining a policy space.
python policies.py data all

The above command will dump a list of charging protocols (one per line) in data/policies_all.csv as well as a surface plot in data/surface_all.png for visualization of the protocol space.

  1. Running a stochastic simulator (for e.g., hyperparameter optimization).
python sim_with_seed.py --C1=3.6 --C2=6 --C3=5.6 --seed=1

The above command will simulate a lifetime for the charging protocol CC1=3.6, CC2=6, CC3=5.6 with a seed of 1. Change the seed to observe more sampled lifetimes.

  1. Running closed-loop optimization (CLO).
python closed_loop_oed.py --round=0 --data_dir='data' --next_batch_dir='batch' --arm_bounds_dir='pred' --early_pred_dir='batch'

This script will run CLO for first round and dump the suggested charging protocols for experimentation in data/batch. The log for this round will be available in data/log.csv. The lifetime estimates at the end of the current round are saved in data/. Before running CLO for next round, please ensure that the early predictions are saved in data/pred/.

See the arguments description in closed_loop_oed.py for further options.

Paper Figures

All the data and code for generating the figures in the paper are available in the figures/ folder.

Note

The primary contributors to this repository are Peter Attia and Aditya Grover. The legacy repository with all the detailed experimental scripts (some of which uses internal infrastructure) is located here. Associated repositories include Arbin test file automation and data processing and early prediction modeling.

battery-fast-charging-optimization's People

Contributors

aditya-grover avatar chueh-ermon avatar petermattia avatar

Watchers

 avatar

Forkers

chinabeatanyone

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.