// loading sometimes fails if a new interpreter is
// created, so
// we use the one from the NengoGraphics.
PythonInterpreter pi = NengoGraphics.getInstance().getPythonInterpreter();
pi.set("___inStream",
new PythonObjectInputStream(new FileInputStream(file)));
org.python.core.PyObject obj = pi.eval("___inStream.readObject()");
objLoaded = obj.__tojava__(Class.forName("ca.nengo.model.Node"));
pi.exec("del ___inStream");
SwingUtilities.invokeLater(new Runnable() {