PyBaMM comes with a small command line interface that can be used to manage parameter sets.
By default, PyBaMM provides parameters in the “input” directory located in the pybamm package
directory.
If you wish to add new parameters, you can first pull a given parameter directory into the current
working directory using the command pybamm_edit_parameter
for manual editing.
By default, PyBaMM first looks for parameter defined in the current working directory before
falling back the package directory if nothing is found locally.
If you wish to access a newly defined parameter set from anywhere in your system, you can use
pybamm_add_parameter
to copy a given parameter directory to the package directory.
To get a list of currently available parameter sets, use pybamm_list_parameters
.
Add a parameter directory to package input directory. This allows the parameters to be used from anywhere in the system.
Example: “add_parameter foo lithium_ion negative_electrodes” will copy directory foo in “pybamm/input/parameters/lithium_ion/negative_electrodes”.
Remove a parameter directory from package input directory.
Example: “rm_parameter foo lithium_ion negative_electrodes” will remove directory foo in “pybamm/input/parameters/lithium_ion/negative_electrodes”.
Copy a given default parameter directory to the current working directory for editing. For example
edit_param(["lithium_ion"])
will create the directory structure:
lithium_ion/
negative_electrodes/
graphite_Chen2020
...
positive_electrodes/
...
in the current working directory.