Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[Roadmap area] Model refactoring #3908

Open
brosaplanella opened this issue Mar 20, 2024 · 0 comments
Open

[Roadmap area] Model refactoring #3908

brosaplanella opened this issue Mar 20, 2024 · 0 comments
Assignees

Comments

@brosaplanella
Copy link
Sponsor Member

We don't have as many contributors adding models to PyBaMM as we'd like. There are a few reasons for this

  • PyBaMM’s submodel structure is too complex, huge barrier to entry
  • You have to add things to the PyBaMM repo, uncertain ownership

We propose "model entry points" as a solution to this. Using entry points, contributors can create models in their own repositories and make them easily available to the rest of the community, without the models having to be added to PyBaMM itself. This will enable a community for battery models that use the PyBaMM infrastructure but are not owned by the PyBaMM team.

Advantages

  • Contributors get to keep models in their own repositories, retain ownership, choose license terms
  • PyBaMM team doesn’t have to endorse models we don’t like
  • All of GitHub’s functionality (issues, discussions, pull requests) are available for each model

How to start

  • Set up a separate repository with an example of adding a model separately outside of PyBaMM
  • Make required changes to PyBaMM to enable this
    • Entry points for models
    • Making basic models compatible with experiments
    • Figure out how to deal with new parameters (define parameters inside the model itself?)
  • Make cookiecutter repository to help with setting up, adding entry points, publishing to pypi, tests, docs, specifying pybamm version(s), etc (as part of the GSoC coookie-cutter project)

Later changes

After this is done, we will be in a much better position to consider fully separating the model code and PDE code

Originally posted by @tinosulzer in #3839 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants