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

Get a working build for PyBaMM – with IDAKLU enabled #1

Open
wants to merge 21 commits into
base: main
Choose a base branch
from

Conversation

agriyakhetarpal
Copy link
Owner

@agriyakhetarpal agriyakhetarpal commented Nov 20, 2024

Description

In progress – this PR compiles OpenBLAS, SUNDIALS, and SuiteSparse as shared libraries loaded as Emscripten side modules with patches applied as necessary, switches from the CasADi Pyodide wheels to CasADi as a C/C++ library for use at compilation time, and configures PyBaMM's current build system to produce a platform-specific wasm32 wheel.

This is blocked by pybamm-team/PyBaMM#4260 at the moment, since no reliable build-time configuration or variable exists to disable threading.

Tip

With the current state of this PR and most of the work done, PyBaMM with the CasADi solver (and without the IDAKLU solver) should already work, since we have compiled everything we need. I shall split that target into a separate PR and integrate it into a GitHub Pages + custom JupyterLite distribution for further use.

Additional context

xref: pybamm-team/PyBaMM#3910

@agriyakhetarpal
Copy link
Owner Author

Almost there! I have to fix the klu_defaults symbol's visibility somehow, so that SUNDIALS can detect that KLU support is working as intended. Maybe it has something to do with main modules/side modules and how they work.

@agriyakhetarpal agriyakhetarpal changed the title Get things working Get a working build for PyBaMM + IDAKLU enabled Nov 20, 2024
@agriyakhetarpal agriyakhetarpal changed the title Get a working build for PyBaMM + IDAKLU enabled Get a working build for PyBaMM (with IDAKLU enabled) Nov 20, 2024
@agriyakhetarpal agriyakhetarpal changed the title Get a working build for PyBaMM (with IDAKLU enabled) Get a working build for PyBaMM – with IDAKLU enabled Nov 20, 2024
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

Successfully merging this pull request may close these issues.

1 participant