Hi Thomas, thanks for your quick reply! Indeed, your link contains what I think the sympy profile was doing:
In [1]: from sympy import init_session In [2]: init_session() and this works just fine in jupyter. Still, it would be nice if there was some shortcut for it as it takes more effort than necessary to remember and to type this. In the past, I had a shell alias for sympy which asks for the sympy profile, but obviously this is not supported any longer. Creating a dedicated sympy kernel as you suggest seems possible but a bit heavy-handed for such a simple thing (and nothing I can tell my students in order to lower the barrier of entry...). Yes, I do need to switch profiles as I am using both pylab and sympy interactively. Funny enough, ipython has a builtin magic for pylab, but none for sympy. I am not sure how much this forum is connected to ipython, but that would be an obvious trivial thing to add that would more or less solve the issue of getting a working sympy console quickly in the most obvious way. Regards, Marcel On Tuesday, August 1, 2017 at 11:50:36 AM UTC+2, takowl wrote: > > Hi Marcel, > > On 1 August 2017 at 09:27, <[email protected] <javascript:>> wrote: > >> After upgrading my Fedora installation to F26, I notice that ipython now >> seems to call jupyter directly which does not have the concept of profiles >> any more, as can be found via google relatively quickly. >> > > IPython, the terminal interface, still works the way it used to: you > should be able to use your profile there. I don't think we ship a sympy > profile any more (I had forgotten we ever did that), but if you work out > the configuration it needs, you should be able to make a profile with > 'ipython profile create sympy', and modify the config file it creates. > > The IPython frontends which talk to a kernel (the notebook, qtconsole and > two-process terminal console) all became Jupyter applications, so they > don't directly support profiles. > > >> What I miss, however, is a canonical replacement for --profile="sympy" as >> a standard profile. It used to set up pretty printing, loading sympy and >> pre-define a few variable names, all pretty convenient. However, the >> profile is now completely gone from my system. I could probably dig up >> some old version on the internet or try to handwrite one myself, but there >> should be a standard replacement mechanism for this? >> > > Sympy has some functions you can call at the start of a session to set up > some amount of integration: > > http://docs.sympy.org/latest/tutorial/printing.html#setting-up-pretty-printing > > We recommend this kind of approach for use in notebooks particularly, > because notebooks which rely on things configured on your computer won't be > easily runnable for anyone without that config. > > But if that's not enough for you, and you have your sympy profile set up, > you can create a dedicated sympy kernel which will launch IPython with your > sympy profile. You'll need to install a kernelspec ( > http://ipython.readthedocs.io/en/stable/install/kernel_install.html), and > then manually modify the kernel.json file to add --profile sympy to the > argv. > > Best wishes, > Thomas > -- You received this message because you are subscribed to the Google Groups "Project Jupyter" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/jupyter/672dcaea-8338-468d-a263-40c92122d9b1%40googlegroups.com. For more options, visit https://groups.google.com/d/optout.
