PyMIF to MIF/Tcl Format Conversion: mifpy2tcl

The mifpy2tcl utility converts PyMIF 1.0 files into MIF/Tcl 2.2 format.

Launching
The mifpy2tcl launch command is:

tclsh oommf.tcl mifpy2tcl
   [-h|--help] [-infile INFILE] [-outfile OUTFILE]
   [-parameters name value ...] [-v|--version]
where
-h or --help
Print help information and stop.
-infile
Read PyMIF input from INFILE. Default is stdin.
-outfile
Write MIF/Tcl output to OUTFILE. Default is stdout.
-parameters
One or more optional name + value pairs, passed to the PyMIF Parameter command.
-v or --version
Print version string and stop.

This utility is used on the fly by the Oxs solvers when processing PyMIF input files, but is also provided for standalone use. It runs oommf/app/oxs/mifpy2tcl.py inside a Python 3 executable to process the PyMIF input file. Treat PyMIF files with the same care as you would other Python scripts.




OOMMF Documentation Team
September 30, 2025