diff_sims#

diff_sims(sim1, sim2, skip_key_diffs=False, skip=None, full=False, output=False, die=False)[source]#

Compute the difference of the summaries of two simulations, and print any values which differ.

Parameters:
  • sim1 (Sim/MultiSim/dict) – either a simulation/MultiSim object or the sim.summary dictionary

  • sim2 (im/dict) – ditto

  • skip_key_diffs (bool) – whether to skip keys that don’t match between sims

  • skip (list) – a list of values to skip

  • full (bool) – whether to print out all values (not just those that differ)

  • output (bool) – whether to return the output as a string (otherwise print)

  • die (bool) – whether to raise an exception if the sims don’t match

  • require_run (bool) – require that the simulations have been run

Example:

s1 = ss.Sim(rand_seed=1).run()
s2 = ss.Sim(rand_seed=2).run()
ss.diff_sims(s1, s2)