Doing multiple runs

Often, MIMOSA needs to be run with multiple values of the same parameter (multiple carbon budgets, multiple discount rates, etc.). While it is possible to simply run the file multiple times, it is much easier to run MIMOSA multiple times directly in the Python script through regular Python loops:

from mimosa import MIMOSA, load_params

for budget in ["500 GtCO2", "700 GtCO2", "1000 GtCO2"]:

    params = load_params()

    params["emissions"]["carbonbudget"] = budget

    model3 = MIMOSA(params)
    model3.solve()

    model3.save(f"run_example3_{budget}")  # (1)!
  1. Don't forget to save each file to a different name, otherwise they will be overwritten at each iteration of the loop.