Skip to content

Commit 69bb924

Browse files
Merge pull request #5056 from medha-14/GSoC
[GSOC 2025] Saving and Loading Custom Models
2 parents e154fec + 9db6435 commit 69bb924

File tree

4 files changed

+1473
-5
lines changed

4 files changed

+1473
-5
lines changed

src/pybamm/__init__.py

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,7 @@
5858
from .expression_tree.operations.jacobian import Jacobian
5959
from .expression_tree.operations.convert_to_casadi import CasadiConverter
6060
from .expression_tree.operations.unpack_symbols import SymbolUnpacker
61+
from .expression_tree.operations.serialise import Serialise
6162

6263
# Model classes
6364
from .models.base_model import BaseModel

src/pybamm/expression_tree/exceptions.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -66,3 +66,9 @@ class DiscretisationError(Exception):
6666
"""A model could not be discretised."""
6767

6868
pass
69+
70+
71+
class InvalidModelJSONError(Exception):
72+
"""Raised when a model JSON file is invalid or cannot be parsed."""
73+
74+
pass

0 commit comments

Comments
 (0)