Skip to content

Commit

Permalink
Adding new imports so code will run
Browse files Browse the repository at this point in the history
  • Loading branch information
kjjarvis committed Oct 13, 2023
1 parent 022247e commit 9a514be
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions examples/04_New Models.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -1427,7 +1427,8 @@
"import matplotlib.pyplot as plt\n",
"import pickle\n",
"import numpy as np\n",
"from progpy.models import BatteryElectroChemEOD"
"from progpy.models import BatteryElectroChemEOD\n",
"from progpy.loading import Piecewise"
]
},
{
Expand Down Expand Up @@ -1527,7 +1528,7 @@
"source": [
"# Variable (piecewise) future loading scheme\n",
"future_loading = Piecewise(\n",
" m.InputContainer,\n",
" batt.InputContainer,\n",
" [600, 1000, 1500, 3000],\n",
" {'i': [3, 2, 1.5, 4]})"
]
Expand Down Expand Up @@ -1603,7 +1604,7 @@
" np.array_equal(voltage_orig, voltage_json_1) and \\\n",
" np.array_equal(voltage_orig, voltage_json_2)\n",
"\n",
"print(f\"The simulated results from the original and serialized models are {'identical. This means that our serialization works!' if are_arrays_same else 'not identical. This means that our serialization does not work.'}!\")"
"print(f\"The simulated results from the original and serialized models are {'identical. This means that our serialization works!' if are_arrays_same else 'not identical. This means that our serialization does not work.'}\")"
]
},
{
Expand Down

0 comments on commit 9a514be

Please sign in to comment.