Verbosity levels#

When calling OOMMF different numbers of information can be shown. We demonstrate the different options for the example macrospin defined in micromagneticmodel

import micromagneticmodel as mm

import oommfc as oc
system = mm.examples.macrospin()
md = oc.MinDriver()
td = oc.TimeDriver()

One summary line (default)#

The default value verbose=1 prints one summary line to the screen.

Running OOMMF (ExeOOMMFRunner)[2023/10/18 12:41]... (0.4 s)
[5]:, t=1e-9, n=10)
Running OOMMF (ExeOOMMFRunner)[2023/10/18 12:41]... (0.3 s)

Silent run#

By setting verbose=0 the calls to OOMMF do not produce any output.

[6]:, verbose=0)
[7]:, t=1e-9, n=10, verbose=0)

Progress bar (TimeDriver only)#

By passing verbose=2 we can get a status bar showing the progress of a running simulations. This feature is only available for the TimeDriver and solely relies on the total number of steps n and the number of files already written to disk. Therefore, the information only gives a rough indication of the progress. The progress bar is not persistent accross notebook sessions. Therefore, an additional summary line is printed at the end of the simulation.

[8]:, t=100e-9, n=50, verbose=2)
Running OOMMF (ExeOOMMFRunner)[2023/10/18 12:41] took 4.1 s

When used with the MinDriver the standard one-line summary is shown instead.

[9]:, verbose=2)
Running OOMMF (ExeOOMMFRunner)[2023/10/18 12:42]... (0.2 s)
# cleanup