user2275987
user2275987

Reputation: 129

Loading sympy in Enthought Canopy causes kernel to die

I just installed Enthought Canopy and it's great but I'm having trouble using simpy in the IPython notebook implementation.

Creating a new notebook in Canopy and then using either

%load_ext sympyprinting
import sympy as sym
from sympy import *

or just

import sympy

causes the kernel to die, with the message, "The kernel has died, would you like to restart it? If you do not restart the kernel, you will be able to save the notebook, but running code will not work until the notebook is reopened."

Ordinarily I would start the html notebook with "ipython notebook --sympy" or some such, but I don't know how to pass the "--[...]" argument while using Canopy. Is this possible, or is there another technique to using Sympy this way? I've already installed Sympy via Canopy's GUI package manager.

PS I'm running on Ubuntu 12.04, with no sort of python installed except the Canopy suite, or anything that Ubuntu might come with by default.

Upvotes: 1

Views: 689

Answers (1)

asmeurer
asmeurer

Reputation: 91620

I don't know if this will solve your problem, but as of SymPy 0.7.2, the IPython printing extension is shipped as part of SymPy. So you should instead do

%load_ext sympy.interactive.ipythonprinting

You can also use the init_printing() function. If you also want to automatically import everything and define common symbol names like x, y, and z, use init_session().

Upvotes: 0

Related Questions