From zvoros at gmail.com Mon Sep 1 03:48:43 2014 From: zvoros at gmail.com (=?windows-1252?Q?Zolt=E1n_V=F6r=F6s?=) Date: Mon, 01 Sep 2014 09:48:43 +0200 Subject: [IPython-dev] Latex highlighting for markdown cells? In-Reply-To: <55FBA463-ED7D-499E-9293-0A5D90245861@gmail.com> References: <4C684A7E-7FEC-4D25-8E5A-BA05EDFD46C5@gmail.com> <5400BA91.1090202@gmail.com> <55FBA463-ED7D-499E-9293-0A5D90245861@gmail.com> Message-ID: <540424DB.9040009@gmail.com> Thanks! I will look into this. Cheers, Zolt?n On 08/31/2014 08:14 PM, Matthias Bussonnier wrote: > > Le 29 ao?t 2014 ? 18:38, Zolt?n V?r?s > a ?crit : > >> Hi Matthias, >> >> I have recently been wondering myself about this. What I wanted to do is >> insert the closing \end{environment} tags in the markdown cell, and >> insert e.g., \frac{}{} and move the cursor back to the first curly >> bracket, if the user types \fra, but syntax highlighting would also be >> useful. Could you point me to some sort of documentation as to how one >> starts out writing a plugin for this? I would be willing to work on this. > > Sorry for the short mail : > > http://codemirror.net/doc/manual.html#modeapi > > Have also a look at this part of code mirror doc : > > Sometimes, it is useful for modes to nest?to have one mode delegate > work to another mode. An example of this kind of mode is > the mixed-mode HTML mode. To implement such nesting, it is usually > necessary to create mode objects and copy states yourself. To create a > mode object, there are CodeMirror.getMode(options, parserConfig), > where the first argument is a configuration object as passed to the > mode constructor function, and the second argument is a mode > specification as in the mode option. To copy a state object, > call CodeMirror.copyState(mode, state), where mode is the mode that > created the given state. > > ? > From rmcgibbo at gmail.com Mon Sep 1 21:42:58 2014 From: rmcgibbo at gmail.com (Robert McGibbon) Date: Mon, 1 Sep 2014 18:42:58 -0700 Subject: [IPython-dev] New WebGL-based protein widget + two questions Message-ID: Hey guys, This weekend I started messing around with the interactive widget system, with the goal of adding interactive protein structure visualization with WebGL to a library I work on ( http://mdtraj.org/). The result is pretty nice, as you can see a short screencast . The code is all here . This was my first time using the widget system, and I have a couple questions. Apologies in advance if they've been addressed previously on the list. 1) What are the recommended best practices for deploying static javascript assets to the browser? You can see in the screencast that I'm calling a function `enable_notebook()` first, which uses a combination of `IPython.display.display()` and `IPython.html.install_nbextension` to configure requirejs with the paths to some libraries I need from the cdns as well as moving our own javascript files into `.ipython/nbextensions`. This is a little cumbersome for the users I think, and there seem to be potentially some unfortunate race conditions if the code that `display()`s the declaration of the browser-side widget view class is in the same cell as the first call that actually creates the widget on the python side. I looked a little bit at Jake Vanderplas's mpld3, and there a lot of the javascript libraries seem to be, by default, pulled directly from github to avoid forcing the user to move the assets into `.ipython/nbextensions`. 2) Is there any support in IPython for creating "static" versions of widgets that don't require a live kernel? This protein view widget, for example, could basically have been rewritten as just a standard _repr_html_ with a lot of javascript (assuming all of the libraries were server from the web instead of /nbextensions). You wouldn't have the interactivity from the python side, but it would still be a very rich experience. Being able to have 'static' views of the widget would enable us to publish some really awesome example notebooks onto the project webpage, for instance ( http://mdtraj.org/latest/examples/). -Robert -------------- next part -------------- An HTML attachment was scrubbed... URL: From nick.bollweg at gmail.com Mon Sep 1 22:39:23 2014 From: nick.bollweg at gmail.com (Nicholas Bollweg) Date: Mon, 1 Sep 2014 22:39:23 -0400 Subject: [IPython-dev] New WebGL-based protein widget + two questions In-Reply-To: References: Message-ID: Looks cool! To your first point: I just wanted to throw out a link here for a cookiecutter template where we might collect some of these concerns: https://github.com/bollwyvl/cookiecutter-ipython-widget > What is currently there is a pattern based on some previous discussions on this list, and some related ones. Its copying/loading approach , encapsulated in a mixin, basically is to copy the package's static folder into nbextensions every time an instance of the widget is loaded into a kernel. Feel free to make use of anything you find there! -------------- next part -------------- An HTML attachment was scrubbed... URL: From takowl at gmail.com Tue Sep 2 03:37:44 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Tue, 2 Sep 2014 08:37:44 +0100 Subject: [IPython-dev] New WebGL-based protein widget + two questions In-Reply-To: References: Message-ID: I've also run into the cumbersome js issue, and the race conditions. We're working on a solution where the widget creation can specify a js module to load with require. More when I'm at a proper keyboard. On 2 Sep 2014 02:43, "Robert McGibbon" wrote: > Hey guys, > > This weekend I started messing around with the interactive widget system, > with the goal of adding interactive > protein structure visualization with WebGL to a library I work on ( > http://mdtraj.org/). The result is pretty nice, as > you can see a short screencast > . The code is all here > . > > This was my first time using the widget system, and I have a couple > questions. Apologies in advance if they've been > addressed previously on the list. > > 1) What are the recommended best practices for deploying static javascript > assets to the browser? You can see in the > screencast that I'm calling a function `enable_notebook()` first, which > uses a combination of `IPython.display.display()` > and `IPython.html.install_nbextension` to configure requirejs with the > paths to some libraries I need from the cdns as > well as moving our own javascript files into `.ipython/nbextensions`. This > is a little cumbersome for the users I think, and > there seem to be potentially some unfortunate race conditions if the code > that `display()`s the declaration of the browser-side > widget view class is in the same cell as the first call that actually > creates the widget on the python side. > > I looked a little bit at Jake Vanderplas's mpld3, and there a lot of the > javascript libraries seem to be, by default, pulled directly > from github to avoid forcing the user to move the assets into > `.ipython/nbextensions`. > > 2) Is there any support in IPython for creating "static" versions of > widgets that don't require a live kernel? This protein view widget, > for example, could basically have been rewritten as just a standard > _repr_html_ with a lot of javascript (assuming all of the libraries > were server from the web instead of /nbextensions). You wouldn't have the > interactivity from the python side, but it would still be a > very rich experience. Being able to have 'static' views of the widget > would enable us to publish some really awesome example > notebooks onto the project webpage, for instance ( > http://mdtraj.org/latest/examples/). > > -Robert > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From H.FANGOHR at soton.ac.uk Tue Sep 2 05:19:10 2014 From: H.FANGOHR at soton.ac.uk (Fangohr H.) Date: Tue, 2 Sep 2014 09:19:10 +0000 Subject: [IPython-dev] Equation rending in html produced via 'ipython nbconvert --to html' not working References: <41D36ECC-2D97-45A2-BC21-DF597954E2D0@soton.ac.uk> Message-ID: <9E850FD2-6EC4-4069-8714-2F897F4A4343@soton.ac.uk> Dear IPython team and users, it looks like I am having an installation/configuration/some-other issue on OS X 10.9.4 that leads to this behaviour: for a notebook x.ipynb (available at http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/x.ipynb) that contains a markdown cell with input ?$x^2$?, the output x.html (available at http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/x.html) is not rendered correctly when an html version of the notebook is produced using ?ipython nbconvert ?to html x.ipynb?. nbconvert-html-issue $> ipython nbconvert --to html x.ipynb [NbConvertApp] Using existing profile dir: u'/Users/fangohr/.ipython/profile_default' [NbConvertApp] Converting notebook x.ipynb to html [NbConvertApp] Support files will be in x_files/ [NbConvertApp] Loaded template full.tpl [NbConvertApp] Writing 184105 bytes to x.html Both files are available at http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/ When http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/x.html is opened in Safari (or Firefox), the equation shows as the source, i.e. "$x^2$? (including the dollars) or - when Node.js was not installed as something like ?\(x\^2\)?. I was hoping for a (mathjax) representation of $x^2$ as in rendered latex, i.e. the 2 in superscript. This used to work in the past, although I can?t make it work now. Some additional information: I started from a new installation of Python via Anaconda 2.0 (Python 2.7, 64 bit for OS X), then updated conda, anaconda, ipython and python-notebook. $> ipython --version 2.2.0 $> ipython notebook --version 2.2.0 $> ipython nbconvert --version 2.2.0 The output of ?iptest? is available at http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/iptest.log Can anybody else see this problem? Any ideas what I am missing? Many thanks, Hans From doug.blank at gmail.com Tue Sep 2 06:19:05 2014 From: doug.blank at gmail.com (Doug Blank) Date: Tue, 2 Sep 2014 06:19:05 -0400 Subject: [IPython-dev] Equation rending in html produced via 'ipython nbconvert --to html' not working In-Reply-To: <9E850FD2-6EC4-4069-8714-2F897F4A4343@soton.ac.uk> References: <41D36ECC-2D97-45A2-BC21-DF597954E2D0@soton.ac.uk> <9E850FD2-6EC4-4069-8714-2F897F4A4343@soton.ac.uk> Message-ID: I had that happen once when I had a tab character embedded right before the string. Try deleting any characters before the first dollar sign. -Doug On Tue, Sep 2, 2014 at 5:19 AM, Fangohr H. wrote: > Dear IPython team and users, > > it looks like I am having an installation/configuration/some-other issue > on OS X 10.9.4 that leads to this behaviour: > > for a notebook x.ipynb (available at > http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/x.ipynb) > that contains a markdown cell with input ?$x^2$?, the output x.html > (available at > http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/x.html) > is not rendered correctly when an html version of the notebook is produced > using ?ipython nbconvert ?to html x.ipynb?. > > nbconvert-html-issue $> ipython nbconvert --to html x.ipynb > [NbConvertApp] Using existing profile dir: > u'/Users/fangohr/.ipython/profile_default' > [NbConvertApp] Converting notebook x.ipynb to html > [NbConvertApp] Support files will be in x_files/ > [NbConvertApp] Loaded template full.tpl > [NbConvertApp] Writing 184105 bytes to x.html > > Both files are available at > http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/ > > When > http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/x.html is > opened in Safari (or Firefox), the equation shows as the source, i.e. > "$x^2$? (including the dollars) or - when Node.js was not installed as > something like ?\(x\^2\)?. > > I was hoping for a (mathjax) representation of $x^2$ as in rendered latex, > i.e. the 2 in superscript. > > This used to work in the past, although I can?t make it work now. > > > Some additional information: > > I started from a new installation of Python via Anaconda 2.0 (Python 2.7, > 64 bit for OS X), then updated conda, anaconda, ipython and python-notebook. > > $> ipython --version > 2.2.0 > $> ipython notebook --version > 2.2.0 > $> ipython nbconvert --version > 2.2.0 > > > The output of ?iptest? is available at > http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/iptest.log > > > Can anybody else see this problem? Any ideas what I am missing? > > > Many thanks, > > Hans > > > > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: From claresloggett at gmail.com Tue Sep 2 07:43:07 2014 From: claresloggett at gmail.com (Clare Sloggett) Date: Tue, 2 Sep 2014 21:43:07 +1000 Subject: [IPython-dev] Reading a password securely in a Notebook Message-ID: Hi all, I am wondering if there's a way to read a string into a variable in a notebook without recording it in the input or output of the cell. I tried using getpass, but it hangs, presumably not passing the input request to the front-end. raw_input() works in pretty much the way I'd like, but of course records the input. IPython.lib.passwd similarly doesn't work (and in any case I need the password as a raw, unencrypted string in this case). I found this issue: https://github.com/ipython/ipython/issues/854 which seems to imply that getpass support has been implemented but won't be included until IPython 3.0 . Is that right? Are there other alternatives? Thanks for any help! Clare -------------- next part -------------- An HTML attachment was scrubbed... URL: From bussonniermatthias at gmail.com Tue Sep 2 08:02:38 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Tue, 2 Sep 2014 05:02:38 -0700 Subject: [IPython-dev] Reading a password securely in a Notebook In-Reply-To: References: Message-ID: <6F29F7B7-2A72-43EA-882E-E56DDB383095@gmail.com> Le 2 sept. 2014 ? 04:43, Clare Sloggett a ?crit : > Hi all, > > I am wondering if there's a way to read a string into a variable in a notebook without recording it in the input or output of the cell. I tried using getpass, but it hangs, presumably not passing the input request to the front-end. raw_input() works in pretty much the way I'd like, but of course records the input. IPython.lib.passwd similarly doesn't work (and in any case I need the password as a raw, unencrypted string in this case). > > I found this issue: https://github.com/ipython/ipython/issues/854 which seems to imply that getpass support has been implemented but won't be included until IPython 3.0 . Is that right? Are there other alternatives? Yes, is currently work on master. ? M > > Thanks for any help! > > Clare > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: From bussonniermatthias at gmail.com Tue Sep 2 08:06:28 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Tue, 2 Sep 2014 05:06:28 -0700 Subject: [IPython-dev] Equation rending in html produced via 'ipython nbconvert --to html' not working In-Reply-To: <9E850FD2-6EC4-4069-8714-2F897F4A4343@soton.ac.uk> References: <41D36ECC-2D97-45A2-BC21-DF597954E2D0@soton.ac.uk> <9E850FD2-6EC4-4069-8714-2F897F4A4343@soton.ac.uk> Message-ID: <792A4C49-9B44-4A79-B6AF-B6EA41277F45@gmail.com> Le 2 sept. 2014 ? 02:19, Fangohr H. a ?crit : > Dear IPython team and users, > > it looks like I am having an installation/configuration/some-other issue on OS X 10.9.4 that leads to this behaviour: > > for a notebook x.ipynb (available at http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/x.ipynb) > that contains a markdown cell with input ?$x^2$?, the output x.html > (available at http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/x.html) > is not rendered correctly when an html version of the notebook is produced using ?ipython nbconvert ?to html x.ipynb?. The file you link to works for me; are you previewing the file with the file:// protocol, or with a local http server ? If it is with file:// then it does not work for security reason at browser level. ? M > > nbconvert-html-issue $> ipython nbconvert --to html x.ipynb > [NbConvertApp] Using existing profile dir: u'/Users/fangohr/.ipython/profile_default' > [NbConvertApp] Converting notebook x.ipynb to html > [NbConvertApp] Support files will be in x_files/ > [NbConvertApp] Loaded template full.tpl > [NbConvertApp] Writing 184105 bytes to x.html > > Both files are available at http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/ > > When http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/x.html is opened in Safari (or Firefox), the equation shows as the source, i.e. "$x^2$? (including the dollars) or - when Node.js was not installed as something like ?\(x\^2\)?. > > I was hoping for a (mathjax) representation of $x^2$ as in rendered latex, i.e. the 2 in superscript. > > This used to work in the past, although I can?t make it work now. > > > Some additional information: > > I started from a new installation of Python via Anaconda 2.0 (Python 2.7, 64 bit for OS X), then updated conda, anaconda, ipython and python-notebook. > > $> ipython --version > 2.2.0 > $> ipython notebook --version > 2.2.0 > $> ipython nbconvert --version > 2.2.0 > > > The output of ?iptest? is available at http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/iptest.log > > > Can anybody else see this problem? Any ideas what I am missing? > > > Many thanks, > > Hans > > > > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From jenshnielsen at gmail.com Tue Sep 2 08:11:39 2014 From: jenshnielsen at gmail.com (Jens Nielsen) Date: Tue, 2 Sep 2014 13:11:39 +0100 Subject: [IPython-dev] Equation rending in html produced via 'ipython nbconvert --to html' not working In-Reply-To: <792A4C49-9B44-4A79-B6AF-B6EA41277F45@gmail.com> References: <41D36ECC-2D97-45A2-BC21-DF597954E2D0@soton.ac.uk> <9E850FD2-6EC4-4069-8714-2F897F4A4343@soton.ac.uk> <792A4C49-9B44-4A79-B6AF-B6EA41277F45@gmail.com> Message-ID: Looking at the source I think this is #6392 https://github.com/ipython/ipython/issues/6392 You can probably modify the link to mathjax either in the template and reexport or just in the html as a work around. /Jens On Tue, Sep 2, 2014 at 1:06 PM, Matthias Bussonnier < bussonniermatthias at gmail.com> wrote: > > Le 2 sept. 2014 ? 02:19, Fangohr H. a ?crit : > > > Dear IPython team and users, > > > > it looks like I am having an installation/configuration/some-other issue > on OS X 10.9.4 that leads to this behaviour: > > > > for a notebook x.ipynb (available at > http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/x.ipynb) > > that contains a markdown cell with input ?$x^2$?, the output x.html > > > > (available at > http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/x.html) > > is not rendered correctly when an html version of the notebook is > produced using ?ipython nbconvert ?to html x.ipynb?. > > > The file you link to works for me; are you previewing the file with the > file:// protocol, or with a local http server ? > If it is with file:// then it does not work for security reason at browser > level. > ? > M > > > > > > > > > nbconvert-html-issue $> ipython nbconvert --to html x.ipynb > > [NbConvertApp] Using existing profile dir: > u'/Users/fangohr/.ipython/profile_default' > > [NbConvertApp] Converting notebook x.ipynb to html > > [NbConvertApp] Support files will be in x_files/ > > [NbConvertApp] Loaded template full.tpl > > [NbConvertApp] Writing 184105 bytes to x.html > > > > Both files are available at > http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/ > > > > When > http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/x.html is > opened in Safari (or Firefox), the equation shows as the source, i.e. > "$x^2$? (including the dollars) or - when Node.js was not installed as > something like ?\(x\^2\)?. > > > > I was hoping for a (mathjax) representation of $x^2$ as in rendered > latex, i.e. the 2 in superscript. > > > > This used to work in the past, although I can?t make it work now. > > > > > > Some additional information: > > > > I started from a new installation of Python via Anaconda 2.0 (Python > 2.7, 64 bit for OS X), then updated conda, anaconda, ipython and > python-notebook. > > > > $> ipython --version > > 2.2.0 > > $> ipython notebook --version > > 2.2.0 > > $> ipython nbconvert --version > > 2.2.0 > > > > > > The output of ?iptest? is available at > http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/iptest.log > > > > > > Can anybody else see this problem? Any ideas what I am missing? > > > > > > Many thanks, > > > > Hans > > > > > > > > > > > > > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: From H.FANGOHR at soton.ac.uk Tue Sep 2 11:11:42 2014 From: H.FANGOHR at soton.ac.uk (Fangohr H.) Date: Tue, 2 Sep 2014 15:11:42 +0000 Subject: [IPython-dev] Equation rending in html produced via 'ipython nbconvert --to html' not working In-Reply-To: References: <41D36ECC-2D97-45A2-BC21-DF597954E2D0@soton.ac.uk> <9E850FD2-6EC4-4069-8714-2F897F4A4343@soton.ac.uk> <792A4C49-9B44-4A79-B6AF-B6EA41277F45@gmail.com> Message-ID: <38D0015F-E99E-4995-8C99-3B4ED6F37D69@soton.ac.uk> Thanks to all the answers. On 2 Sep 2014, at 13:11, Jens Nielsen > wrote: Looking at the source I think this is #6392 https://github.com/ipython/ipython/issues/6392 You can probably modify the link to mathjax either in the template and reexport or just in the html as a work around. Yes, this is the one: the server c328740.ssl.cf1.rackcdn.com needs to be replaced by cdn.mathjax.org, then it works. I understand that this is meant to be fixed in 2.2 (based on the comments in https://github.com/ipython/ipython/issues/6392) although it seems not to be fixed yet from my experience. Should I file this as a bug report? Just in case others have the same issue: A cheap way to fix this (without having to modify ipython-notebook source) for file x.html is this: sed -i .bak s/c328740.ssl.cf1.rackcdn.com/cdn.mathjax.org/ x.html To do it for all files in subtree, we can use find . -name '*.html' -exec sed -i .bak s/c328740.ssl.cf1.rackcdn.com/cdn.mathjax.org/ '{}' \; Thanks, Hans /Jens On Tue, Sep 2, 2014 at 1:06 PM, Matthias Bussonnier > wrote: Le 2 sept. 2014 ? 02:19, Fangohr H. > a ?crit : > Dear IPython team and users, > > it looks like I am having an installation/configuration/some-other issue on OS X 10.9.4 that leads to this behaviour: > > for a notebook x.ipynb (available at http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/x.ipynb) > that contains a markdown cell with input ?$x^2$?, the output x.html > (available at http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/x.html) > is not rendered correctly when an html version of the notebook is produced using ?ipython nbconvert ?to html x.ipynb?. The file you link to works for me; are you previewing the file with the file:// protocol, or with a local http server ? If it is with file:// then it does not work for security reason at browser level. ? M > > nbconvert-html-issue $> ipython nbconvert --to html x.ipynb > [NbConvertApp] Using existing profile dir: u'/Users/fangohr/.ipython/profile_default' > [NbConvertApp] Converting notebook x.ipynb to html > [NbConvertApp] Support files will be in x_files/ > [NbConvertApp] Loaded template full.tpl > [NbConvertApp] Writing 184105 bytes to x.html > > Both files are available at http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/ > > When http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/x.html is opened in Safari (or Firefox), the equation shows as the source, i.e. "$x^2$? (including the dollars) or - when Node.js was not installed as something like ?\(x\^2\)?. > > I was hoping for a (mathjax) representation of $x^2$ as in rendered latex, i.e. the 2 in superscript. > > This used to work in the past, although I can?t make it work now. > > > Some additional information: > > I started from a new installation of Python via Anaconda 2.0 (Python 2.7, 64 bit for OS X), then updated conda, anaconda, ipython and python-notebook. > > $> ipython --version > 2.2.0 > $> ipython notebook --version > 2.2.0 > $> ipython nbconvert --version > 2.2.0 > > > The output of ?iptest? is available at http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/iptest.log > > > Can anybody else see this problem? Any ideas what I am missing? > > > Many thanks, > > Hans > > > > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev _______________________________________________ IPython-dev mailing list IPython-dev at scipy.org http://mail.scipy.org/mailman/listinfo/ipython-dev _______________________________________________ IPython-dev mailing list IPython-dev at scipy.org http://mail.scipy.org/mailman/listinfo/ipython-dev From jenshnielsen at gmail.com Tue Sep 2 11:15:20 2014 From: jenshnielsen at gmail.com (Jens Nielsen) Date: Tue, 2 Sep 2014 16:15:20 +0100 Subject: [IPython-dev] Equation rending in html produced via 'ipython nbconvert --to html' not working In-Reply-To: <38D0015F-E99E-4995-8C99-3B4ED6F37D69@soton.ac.uk> References: <41D36ECC-2D97-45A2-BC21-DF597954E2D0@soton.ac.uk> <9E850FD2-6EC4-4069-8714-2F897F4A4343@soton.ac.uk> <792A4C49-9B44-4A79-B6AF-B6EA41277F45@gmail.com> <38D0015F-E99E-4995-8C99-3B4ED6F37D69@soton.ac.uk> Message-ID: Hi Hans, Look below Min's initial comment. It was fixed most places in 2.2, but there was a leftover reference in the template. /Jens On Tue, Sep 2, 2014 at 4:11 PM, Fangohr H. wrote: > Thanks to all the answers. > > On 2 Sep 2014, at 13:11, Jens Nielsen jenshnielsen at gmail.com>> wrote: > > Looking at the source I think this is #6392 > https://github.com/ipython/ipython/issues/6392 > > You can probably modify the link to mathjax either in the template and > reexport or just in the html as a work around. > > Yes, this is the one: the server c328740.ssl.cf1.rackcdn.com< > http://ssl.cf1.rackcdn.com> needs to be replaced by cdn.mathjax.org< > http://cdn.mathjax.org>, then it works. > > I understand that this is meant to be fixed in 2.2 (based on the comments > in https://github.com/ipython/ipython/issues/6392) although it seems not > to be fixed yet from my experience. Should I file this as a bug report? > > Just in case others have the same issue: A cheap way to fix this (without > having to modify ipython-notebook source) for file x.html is this: > > sed -i .bak s/c328740.ssl.cf1.rackcdn.com/cdn.mathjax.org/< > http://ssl.cf1.rackcdn.com/cdn.mathjax.org/> x.html > > To do it for all files in subtree, we can use > > find . -name '*.html' -exec sed -i .bak s/ > c328740.ssl.cf1.rackcdn.com/cdn.mathjax.org/< > http://ssl.cf1.rackcdn.com/cdn.mathjax.org/> '{}' \; > > > > Thanks, > > Hans > > > > /Jens > > > On Tue, Sep 2, 2014 at 1:06 PM, Matthias Bussonnier < > bussonniermatthias at gmail.com> wrote: > > Le 2 sept. 2014 ? 02:19, Fangohr H. H.FANGOHR at soton.ac.uk>> a ?crit : > > > Dear IPython team and users, > > > > it looks like I am having an installation/configuration/some-other issue > on OS X 10.9.4 that leads to this behaviour: > > > > for a notebook x.ipynb (available at > http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/x.ipynb) > > that contains a markdown cell with input ?$x^2$?, the output x.html > > > > (available at > http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/x.html) > > is not rendered correctly when an html version of the notebook is > produced using ?ipython nbconvert ?to html x.ipynb?. > > > The file you link to works for me; are you previewing the file with the > file:// protocol, or with a local http server ? > If it is with file:// then it does not work for security reason at browser > level. > ? > M > > > > > > > > > nbconvert-html-issue $> ipython nbconvert --to html x.ipynb > > [NbConvertApp] Using existing profile dir: > u'/Users/fangohr/.ipython/profile_default' > > [NbConvertApp] Converting notebook x.ipynb to html > > [NbConvertApp] Support files will be in x_files/ > > [NbConvertApp] Loaded template full.tpl > > [NbConvertApp] Writing 184105 bytes to x.html > > > > Both files are available at > http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/ > > > > When > http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/x.html is > opened in Safari (or Firefox), the equation shows as the source, i.e. > "$x^2$? (including the dollars) or - when Node.js was not installed as > something like ?\(x\^2\)?. > > > > I was hoping for a (mathjax) representation of $x^2$ as in rendered > latex, i.e. the 2 in superscript. > > > > This used to work in the past, although I can?t make it work now. > > > > > > Some additional information: > > > > I started from a new installation of Python via Anaconda 2.0 (Python > 2.7, 64 bit for OS X), then updated conda, anaconda, ipython and > python-notebook. > > > > $> ipython --version > > 2.2.0 > > $> ipython notebook --version > > 2.2.0 > > $> ipython nbconvert --version > > 2.2.0 > > > > > > The output of ?iptest? is available at > http://www.southampton.ac.uk/~fangohr/temp/nbconvert-html-issue/iptest.log > > > > > > Can anybody else see this problem? Any ideas what I am missing? > > > > > > Many thanks, > > > > Hans > > > > > > > > > > > > > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: From gustavo.goretkin at gmail.com Thu Sep 4 12:34:08 2014 From: gustavo.goretkin at gmail.com (Gustavo Goretkin) Date: Thu, 4 Sep 2014 12:34:08 -0400 Subject: [IPython-dev] IPython inputhook, higher rate? Message-ID: ---------- Forwarded message ---------- From: Gustavo Goretkin Date: Thu, Aug 28, 2014 at 1:25 PM Subject: IPython inputhook, higher rate? To: ipython-user at scipy.org I'm using IPython.lib.inputhook to run steps in a simulation (Box2D and pygame, which uses sdl). When I run this step in my own loop, I can get many hundred of Hertz. When I use set_inputhook, I can only get 8 Hz. When IPython is integrated with GUI backends (like any of the matplotlib interactive backends), it's very responsive. Is there a setting I'm missing? Thank you! Gustavo def run_from_ipython(): > try: > __IPYTHON__ > return True > except NameError: > return False > > if not run_from_ipython(): > while domain.running: > domain.run_step() > else: > from IPython.lib import inputhook > > def step(): > domain.run_step() > return domain.running > > inputhook.set_inputhook(step) > -------------- next part -------------- An HTML attachment was scrubbed... URL: From claresloggett at gmail.com Thu Sep 4 20:33:11 2014 From: claresloggett at gmail.com (Clare Sloggett) Date: Fri, 5 Sep 2014 10:33:11 +1000 Subject: [IPython-dev] Reading a password securely in a Notebook In-Reply-To: <6F29F7B7-2A72-43EA-882E-E56DDB383095@gmail.com> References: <6F29F7B7-2A72-43EA-882E-E56DDB383095@gmail.com> Message-ID: Hi Matthias, Not sure if I am understanding right but I assume you're suggesting installing from source from github, i.e. using 3.0. That will help me for testing purposes, thanks! I was hoping there was some way to achieve what I want in 2.2 though? 2.x is what's installed most places I do work. Cheers, Clare On 2 September 2014 22:02, Matthias Bussonnier wrote: > > Le 2 sept. 2014 ? 04:43, Clare Sloggett a ?crit > : > > Hi all, > > I am wondering if there's a way to read a string into a variable in a > notebook without recording it in the input or output of the cell. I tried > using getpass, but it hangs, presumably not passing the input request to > the front-end. raw_input() works in pretty much the way I'd like, but of > course records the input. IPython.lib.passwd similarly doesn't work (and in > any case I need the password as a raw, unencrypted string in this case). > > I found this issue: https://github.com/ipython/ipython/issues/854 which > seems to imply that getpass support has been implemented but won't be > included until IPython 3.0 . Is that right? Are there other alternatives? > > > Yes, > is currently work on master. > ? > M > > > > Thanks for any help! > > Clare > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bussonniermatthias at gmail.com Thu Sep 4 20:52:50 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Thu, 4 Sep 2014 17:52:50 -0700 Subject: [IPython-dev] Reading a password securely in a Notebook In-Reply-To: References: <6F29F7B7-2A72-43EA-882E-E56DDB383095@gmail.com> Message-ID: <8701D857-BC48-48E5-92CD-DE6AAD92DE35@gmail.com> Le 4 sept. 2014 ? 17:33, Clare Sloggett a ?crit : > Hi Matthias, > > Not sure if I am understanding right but I assume you're suggesting installing from source from github, i.e. using 3.0. That will help me for testing purposes, thanks! Yes, > > I was hoping there was some way to achieve what I want in 2.2 though? 2.x is what's installed most places I do work. > > Cheers, > Clare Non, it is not doable on 2.x. -- M From ssanderson at quantopian.com Fri Sep 5 11:01:57 2014 From: ssanderson at quantopian.com (ssanderson) Date: Fri, 5 Sep 2014 08:01:57 -0700 (PDT) Subject: [IPython-dev] Registering Input Transformers that can Reject Input Message-ID: <1409929317612-5070376.post@n6.nabble.com> Hi all, I'm currently working on a project over at Quantopian that involves running a notebook server in an environment that's sandboxed in various ways. One thing that I'd like to be able to do is hook in some of our AST transformation machinery for statically rejecting certain classes of inputs (e.g. code can't do exec/eval and can only import certain modules). I can do this currently by writing my own Python kernel and doing an AST pass in do_execute, but that means I can't easily support IPython's extended syntax. It seems like the right place for me to do this sort of extension is by passing a list of transformers to InteractiveShell, but the issue I run into there is that there doesn't seem to be any notion of an AST Transformer that's allowed to fail or signal rejection in some way. I could probably work around this by having our transformers just replace the input code with entirely different code that raises an appropriate exception, but that makes it pretty cumbersome to change the behavior for different sorts of inputs, so I'm wondering whether you guys would consider it in-scope for InteractiveShell to support a notion of NodeTransformers that can reject input. Alternatively, if you think there's a better way for me to do this sort of thing given the current codebase, I'd be happy to hear. Thanks, -Scott Sanderson -- View this message in context: http://python.6.x6.nabble.com/Registering-Input-Transformers-that-can-Reject-Input-tp5070376.html Sent from the IPython - Development mailing list archive at Nabble.com. From takowl at gmail.com Fri Sep 5 12:35:38 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Fri, 5 Sep 2014 09:35:38 -0700 Subject: [IPython-dev] Registering Input Transformers that can Reject Input In-Reply-To: <1409929317612-5070376.post@n6.nabble.com> References: <1409929317612-5070376.post@n6.nabble.com> Message-ID: Hi Scott, Flippant answer: just remove the offending nodes and run the code without them! Serious answer: yes, I think that would be in scope for IPython. String-based input transformers can now reject input (by raising SyntaxError), so it makes sense for AST based transformers to have the same possibility. Though I'm not sure yet quite what semantics I'd like. SyntaxError seems a bit wrong when the code is valid Python syntax. Maybe we should define our own exception class for this. A couple of cautions about doing sandboxing this way: - AST transformers only run on code run directly in IPython - if you can run another file (e.g. with %run, import, execfile, IPython !shell escapes, etc.), this will not check its AST. So you will also need to take care to prevent the user from either writing files or running them, both of which are tricky. - Checking Python code like this is hard. E.g. if you check for Name nodes with id='eval', I can bypass it by doing this: import builtins ev = getattr(builtins, 'eval') ev('unchecked_code') Sandboxing is possible, but you have to restrict quite a few things to make it stick. Thomas On 5 September 2014 08:01, ssanderson wrote: > Hi all, > > I'm currently working on a project over at Quantopian > that involves running a notebook server in an > environment that's sandboxed in various ways. One thing that I'd like to > be > able to do is hook in some of our AST transformation machinery for > statically rejecting certain classes of inputs (e.g. code can't do > exec/eval > and can only import certain modules). I can do this currently by writing > my > own Python kernel and doing an AST pass in do_execute, but that means I > can't easily support IPython's extended syntax. > > It seems like the right place for me to do this sort of extension is by > passing a list of transformers to InteractiveShell, but the issue I run > into > there is that there doesn't seem to be any notion of an AST Transformer > that's allowed to fail or signal rejection in some way. I could probably > work around this by having our transformers just replace the input code > with > entirely different code that raises an appropriate exception, but that > makes > it pretty cumbersome to change the behavior for different sorts of inputs, > so I'm wondering whether you guys would consider it in-scope for > InteractiveShell to support a notion of NodeTransformers that can reject > input. > > Alternatively, if you think there's a better way for me to do this sort of > thing given the current codebase, I'd be happy to hear. > > Thanks, > -Scott Sanderson > > > > -- > View this message in context: > http://python.6.x6.nabble.com/Registering-Input-Transformers-that-can-Reject-Input-tp5070376.html > Sent from the IPython - Development mailing list archive at Nabble.com. > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ssanderson at quantopian.com Fri Sep 5 13:36:32 2014 From: ssanderson at quantopian.com (ssanderson) Date: Fri, 5 Sep 2014 10:36:32 -0700 (PDT) Subject: [IPython-dev] Registering Input Transformers that can Reject Input In-Reply-To: References: <1409929317612-5070376.post@n6.nabble.com> Message-ID: <1409938592373-5070401.post@n6.nabble.com> Hi Thomas, Glad to hear that it sounds like this makes sense for the main line. We're well aware of the difficulties of securely executing untrusted Python code; in a lot of ways solving that problem well is more important to our business than any of the financial simulation tools that are ostensibly our product! As you note, there are all sorts of ways to dynamically get access to dangerous things (vars, eval, exec, and getattr are the ones we see the most, but we also see breakout attempts using more exotic things like the func_globals attribute on function objects). We do a fair amount of runtime sandboxing in addition to the static checks, but static analysis/transformation has proven to be one of the best tools available to us. As for the expected semantics, our current infrastructure builds a list of violations on a NodeTransformer and just stores them to be converted into a custom SecurityViolation exception elsewhere, but looking at InteractiveShell.transform_ast I think it makes more sense to raise an exception than to have the shell check something like a `failed` attribute on the transformer. The current behavior seems to be that any NodeTransformer that raises is considered broken and removed from the shell, so there would need to be a specific exception class used to signal "this code is broken, not me!" If you think it makes sense to do so, I'd be happy to try and put together a PR for this. -Scott -- View this message in context: http://python.6.x6.nabble.com/Registering-Input-Transformers-that-can-Reject-Input-tp5070376p5070401.html Sent from the IPython - Development mailing list archive at Nabble.com. From doug.blank at gmail.com Fri Sep 5 17:03:31 2014 From: doug.blank at gmail.com (Doug Blank) Date: Fri, 5 Sep 2014 17:03:31 -0400 Subject: [IPython-dev] Javascript in nbconverted html? Message-ID: I'm trying to understand why JavaScript output shows in some nbconverted notebooks, and other notebooks don't show their output. For example, here is a set of Google Charts that render JavaScript nicely: http://nbviewer.ipython.org/urls/bitbucket.org/ipre/calico/raw/master/notebooks/Python/Google%20Charts.ipynb But these don't (it is the last one I am especially wondering about): http://nbviewer.ipython.org/gist/rdhyee/6131622 http://nbviewer.ipython.org/url/jupyter.cs.brynmawr.edu/hub/dblank/public/Processing%20Tests.ipynb/%3Fraw I don't see anything in the browser console regarding errors or security issues. Any insight appreciated! -Doug -------------- next part -------------- An HTML attachment was scrubbed... URL: From jakevdp at cs.washington.edu Fri Sep 5 17:10:35 2014 From: jakevdp at cs.washington.edu (Jacob Vanderplas) Date: Fri, 5 Sep 2014 14:10:35 -0700 Subject: [IPython-dev] Javascript in nbconverted html? In-Reply-To: References: Message-ID: Those look to be jquery problems. As I recall, in the live notebook, jquery is loaded as part of the background environment. When you render the notebook as standalone HTML, jquery is not loaded unless you do it explicitly. Hope that helps, Jake On Fri, Sep 5, 2014 at 2:03 PM, Doug Blank wrote: > I'm trying to understand why JavaScript output shows in some nbconverted > notebooks, and other notebooks don't show their output. > > For example, here is a set of Google Charts that render JavaScript nicely: > > > http://nbviewer.ipython.org/urls/bitbucket.org/ipre/calico/raw/master/notebooks/Python/Google%20Charts.ipynb > > But these don't (it is the last one I am especially wondering about): > > http://nbviewer.ipython.org/gist/rdhyee/6131622 > > > http://nbviewer.ipython.org/url/jupyter.cs.brynmawr.edu/hub/dblank/public/Processing%20Tests.ipynb/%3Fraw > > I don't see anything in the browser console regarding errors or security > issues. Any insight appreciated! > > -Doug > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ellisonbg at gmail.com Fri Sep 5 18:15:18 2014 From: ellisonbg at gmail.com (Brian Granger) Date: Fri, 5 Sep 2014 15:15:18 -0700 Subject: [IPython-dev] Javascript in nbconverted html? In-Reply-To: References: Message-ID: In master jquery should be loaded onto the nbconvert output page, but only if you use the full html style. Otherwise you have to add it yourself. On Fri, Sep 5, 2014 at 2:10 PM, Jacob Vanderplas wrote: > Those look to be jquery problems. As I recall, in the live notebook, jquery > is loaded as part of the background environment. When you render the > notebook as standalone HTML, jquery is not loaded unless you do it > explicitly. > Hope that helps, > Jake > > > On Fri, Sep 5, 2014 at 2:03 PM, Doug Blank wrote: >> >> I'm trying to understand why JavaScript output shows in some nbconverted >> notebooks, and other notebooks don't show their output. >> >> For example, here is a set of Google Charts that render JavaScript nicely: >> >> >> http://nbviewer.ipython.org/urls/bitbucket.org/ipre/calico/raw/master/notebooks/Python/Google%20Charts.ipynb >> >> But these don't (it is the last one I am especially wondering about): >> >> http://nbviewer.ipython.org/gist/rdhyee/6131622 >> >> >> http://nbviewer.ipython.org/url/jupyter.cs.brynmawr.edu/hub/dblank/public/Processing%20Tests.ipynb/%3Fraw >> >> I don't see anything in the browser console regarding errors or security >> issues. Any insight appreciated! >> >> -Doug >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -- Brian E. Granger Cal Poly State University, San Luis Obispo @ellisonbg on Twitter and GitHub bgranger at calpoly.edu and ellisonbg at gmail.com From takowl at gmail.com Fri Sep 5 18:23:35 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Fri, 5 Sep 2014 15:23:35 -0700 Subject: [IPython-dev] Registering Input Transformers that can Reject Input In-Reply-To: <1409938592373-5070401.post@n6.nabble.com> References: <1409929317612-5070376.post@n6.nabble.com> <1409938592373-5070401.post@n6.nabble.com> Message-ID: Hi Scott, Great, you clearly know what you're doing. Yes, I think I would have the transformers raise a specific exception class, rather than setting something that the shell needs to check after the fact. A PR for this would be welcome. Thanks, Thomas On 5 September 2014 10:36, ssanderson wrote: > Hi Thomas, > > Glad to hear that it sounds like this makes sense for the main line. > > We're well aware of the difficulties of securely executing untrusted Python > code; in a lot of ways solving that problem well is more important to our > business than any of the financial simulation tools that are ostensibly our > product! As you note, there are all sorts of ways to dynamically get > access > to dangerous things (vars, eval, exec, and getattr are the ones we see the > most, but we also see breakout attempts using more exotic things like the > func_globals attribute on function objects). We do a fair amount of > runtime > sandboxing in addition to the static checks, but static > analysis/transformation has proven to be one of the best tools available to > us. > > As for the expected semantics, our current infrastructure builds a list of > violations on a NodeTransformer and just stores them to be converted into a > custom SecurityViolation exception elsewhere, but looking at > InteractiveShell.transform_ast I think it makes more sense to raise an > exception than to have the shell check something like a `failed` attribute > on the transformer. > > The current behavior seems to be that any NodeTransformer that raises is > considered broken and removed from the shell, so there would need to be a > specific exception class used to signal "this code is broken, not me!" > > If you think it makes sense to do so, I'd be happy to try and put together > a > PR for this. > > -Scott > > > > -- > View this message in context: > http://python.6.x6.nabble.com/Registering-Input-Transformers-that-can-Reject-Input-tp5070376p5070401.html > Sent from the IPython - Development mailing list archive at Nabble.com. > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: From doug.blank at gmail.com Fri Sep 5 19:01:46 2014 From: doug.blank at gmail.com (Doug Blank) Date: Fri, 5 Sep 2014 19:01:46 -0400 Subject: [IPython-dev] Javascript in nbconverted html? In-Reply-To: References: Message-ID: Thanks to both of you for the hints... it looks like it is a Javascript issue... getting those resolved does indeed work! -Doug On Fri, Sep 5, 2014 at 6:15 PM, Brian Granger wrote: > In master jquery should be loaded onto the nbconvert output page, but > only if you use the full html style. Otherwise you have to add it > yourself. > > On Fri, Sep 5, 2014 at 2:10 PM, Jacob Vanderplas > wrote: > > Those look to be jquery problems. As I recall, in the live notebook, > jquery > > is loaded as part of the background environment. When you render the > > notebook as standalone HTML, jquery is not loaded unless you do it > > explicitly. > > Hope that helps, > > Jake > > > > > > On Fri, Sep 5, 2014 at 2:03 PM, Doug Blank wrote: > >> > >> I'm trying to understand why JavaScript output shows in some nbconverted > >> notebooks, and other notebooks don't show their output. > >> > >> For example, here is a set of Google Charts that render JavaScript > nicely: > >> > >> > >> > http://nbviewer.ipython.org/urls/bitbucket.org/ipre/calico/raw/master/notebooks/Python/Google%20Charts.ipynb > >> > >> But these don't (it is the last one I am especially wondering about): > >> > >> http://nbviewer.ipython.org/gist/rdhyee/6131622 > >> > >> > >> > http://nbviewer.ipython.org/url/jupyter.cs.brynmawr.edu/hub/dblank/public/Processing%20Tests.ipynb/%3Fraw > >> > >> I don't see anything in the browser console regarding errors or security > >> issues. Any insight appreciated! > >> > >> -Doug > >> > >> > >> _______________________________________________ > >> IPython-dev mailing list > >> IPython-dev at scipy.org > >> http://mail.scipy.org/mailman/listinfo/ipython-dev > >> > > > > > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > > > -- > Brian E. Granger > Cal Poly State University, San Luis Obispo > @ellisonbg on Twitter and GitHub > bgranger at calpoly.edu and ellisonbg at gmail.com > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew.chen at berkeley.edu Fri Sep 5 23:08:37 2014 From: andrew.chen at berkeley.edu (Andrew Chen) Date: Fri, 5 Sep 2014 20:08:37 -0700 Subject: [IPython-dev] Jupyter notebook at UC Berkeley Hackathon Message-ID: Hello IPython-dev: We are currently in a hackathon at UC Berkeley and want to extend the jupyter notebook with new features! Over the summer, we've been doing small hacks on the ipython notebooks from writing tools for cross-notebook imports, joystick (xbox controller) widgets, capability for live-tuning control loops, and controlling robots and physical devices. If anybody has ideas and suggestions for jupyter notebook that are hurting for implementation, we'd be happy to help. We'd also love to have company in the Wozniak Lounge from 10am to 11pm! (tomorrow, 9/6) -------------- next part -------------- An HTML attachment was scrubbed... URL: From rgbkrk at gmail.com Sat Sep 6 00:39:06 2014 From: rgbkrk at gmail.com (Kyle Kelley) Date: Fri, 5 Sep 2014 21:39:06 -0700 Subject: [IPython-dev] Jupyter notebook at UC Berkeley Hackathon In-Reply-To: References: Message-ID: Cool! I'll be there for that before flying out! On Friday, September 5, 2014, Andrew Chen wrote: > Hello IPython-dev: > > We are currently in a hackathon at UC Berkeley and want to extend the > jupyter notebook with new features! > > Over the summer, we've been doing small hacks on the ipython notebooks > from writing tools for cross-notebook imports, joystick (xbox controller) > widgets, capability for live-tuning control loops, and controlling robots > and physical devices. > > If anybody has ideas and suggestions for jupyter notebook that are hurting > for implementation, we'd be happy to help. > > We'd also love to have company in the Wozniak Lounge from 10am to 11pm! > (tomorrow, 9/6) > -- Kyle Kelley (@rgbkrk ; http://lambdaops.com) -------------- next part -------------- An HTML attachment was scrubbed... URL: From claresloggett at gmail.com Sat Sep 6 01:25:50 2014 From: claresloggett at gmail.com (Clare Sloggett) Date: Sat, 6 Sep 2014 15:25:50 +1000 Subject: [IPython-dev] Reading a password securely in a Notebook In-Reply-To: <8701D857-BC48-48E5-92CD-DE6AAD92DE35@gmail.com> References: <6F29F7B7-2A72-43EA-882E-E56DDB383095@gmail.com> <8701D857-BC48-48E5-92CD-DE6AAD92DE35@gmail.com> Message-ID: Thanks again Matthias! On 5 September 2014 10:52, Matthias Bussonnier wrote: > > Le 4 sept. 2014 ? 17:33, Clare Sloggett a ?crit > : > > > Hi Matthias, > > > > Not sure if I am understanding right but I assume you're suggesting > installing from source from github, i.e. using 3.0. That will help me for > testing purposes, thanks! > > Yes, > > > > > I was hoping there was some way to achieve what I want in 2.2 though? > 2.x is what's installed most places I do work. > > > > Cheers, > > Clare > > Non, it is not doable on 2.x. > -- > M > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: From takowl at gmail.com Sat Sep 6 01:29:20 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Fri, 5 Sep 2014 22:29:20 -0700 Subject: [IPython-dev] Jupyter notebook at UC Berkeley Hackathon In-Reply-To: References: Message-ID: I'll also come for some of the day. On 5 Sep 2014 21:39, "Kyle Kelley" wrote: > Cool! I'll be there for that before flying out! > > On Friday, September 5, 2014, Andrew Chen > wrote: > >> Hello IPython-dev: >> >> We are currently in a hackathon at UC Berkeley and want to extend the >> jupyter notebook with new features! >> >> Over the summer, we've been doing small hacks on the ipython notebooks >> from writing tools for cross-notebook imports, joystick (xbox controller) >> widgets, capability for live-tuning control loops, and controlling robots >> and physical devices. >> >> If anybody has ideas and suggestions for jupyter notebook that are >> hurting for implementation, we'd be happy to help. >> >> We'd also love to have company in the Wozniak Lounge from 10am to 11pm! >> (tomorrow, 9/6) >> > > > -- > Kyle Kelley (@rgbkrk ; http://lambdaops.com) > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From kikocorreoso at gmail.com Sat Sep 6 08:25:53 2014 From: kikocorreoso at gmail.com (Kiko) Date: Sat, 6 Sep 2014 14:25:53 +0200 Subject: [IPython-dev] nbconvert and templates Message-ID: Hi all I was trying to make a standard template to export a notebook to a basic html format in order to provide a simple template with ipy2wp ( https://github.com/Pybonacci/ipy2wp, asnd IPython notebook to html converter and publisher for the wordpress platform) to allow people to customise their own templates. After some hacking I can't avoid all the:
... And other stuff that is introduced with the basic.tpl (html) template. I can post process the final converted html but I think it would be easier to do it directly with nbconvert and Jinja2. Can someone point me to some docs or examples to try to understand how the conversion is done. I read the exporters code, the preprocessors code, I tried to learn a little bit about Jinja2 but I'm no able to create a template to extend basic.tpl and can do what I want. I don't know when all the nbconvert machinery is adding all this tags, the prompts,... P.D.: I already looked at nbconvert-examples repo, I googled and tried to search in the mailist,... :-( P.D.2: I will try to write something in the wiki or create a notebook explaining the process in order to let other people customise their own templates. Thanks in advance. Kind regards. -------------- next part -------------- An HTML attachment was scrubbed... URL: From jason-sage at creativetrax.com Sat Sep 6 09:47:30 2014 From: jason-sage at creativetrax.com (Jason Grout) Date: Sat, 06 Sep 2014 09:47:30 -0400 Subject: [IPython-dev] Jupyter notebook at UC Berkeley Hackathon In-Reply-To: References: Message-ID: <540B1072.9000009@creativetrax.com> On 9/5/14, 23:08, Andrew Chen wrote: > Over the summer, we've been doing small hacks on the ipython notebooks > from writing tools for cross-notebook imports, joystick (xbox > controller) widgets, capability for live-tuning control loops, and > controlling robots and physical devices. That's really cool. Are you developing these as open-source hacks, and are they posted somewhere we can see? Thanks, Jason From rgbkrk at gmail.com Sat Sep 6 12:44:48 2014 From: rgbkrk at gmail.com (Kyle Kelley) Date: Sat, 6 Sep 2014 09:44:48 -0700 Subject: [IPython-dev] Jupyter notebook at UC Berkeley Hackathon In-Reply-To: References: Message-ID: Hey, we don't have key cards and can't make it up the elevator at soda hall. Can you help matthias and I get upstairs? On Friday, September 5, 2014, Andrew Chen wrote: > Hello IPython-dev: > > We are currently in a hackathon at UC Berkeley and want to extend the > jupyter notebook with new features! > > Over the summer, we've been doing small hacks on the ipython notebooks > from writing tools for cross-notebook imports, joystick (xbox controller) > widgets, capability for live-tuning control loops, and controlling robots > and physical devices. > > If anybody has ideas and suggestions for jupyter notebook that are hurting > for implementation, we'd be happy to help. > > We'd also love to have company in the Wozniak Lounge from 10am to 11pm! > (tomorrow, 9/6) > -- Kyle Kelley (@rgbkrk ; http://lambdaops.com) -------------- next part -------------- An HTML attachment was scrubbed... URL: From rgbkrk at gmail.com Sat Sep 6 12:51:45 2014 From: rgbkrk at gmail.com (Kyle Kelley) Date: Sat, 6 Sep 2014 09:51:45 -0700 Subject: [IPython-dev] Jupyter notebook at UC Berkeley Hackathon In-Reply-To: References: Message-ID: Never mind, we have snuck in. On Saturday, September 6, 2014, Kyle Kelley wrote: > Hey, we don't have key cards and can't make it up the elevator at soda > hall. Can you help matthias and I get upstairs? > > On Friday, September 5, 2014, Andrew Chen > wrote: > >> Hello IPython-dev: >> >> We are currently in a hackathon at UC Berkeley and want to extend the >> jupyter notebook with new features! >> >> Over the summer, we've been doing small hacks on the ipython notebooks >> from writing tools for cross-notebook imports, joystick (xbox controller) >> widgets, capability for live-tuning control loops, and controlling robots >> and physical devices. >> >> If anybody has ideas and suggestions for jupyter notebook that are >> hurting for implementation, we'd be happy to help. >> >> We'd also love to have company in the Wozniak Lounge from 10am to 11pm! >> (tomorrow, 9/6) >> > > > -- > Kyle Kelley (@rgbkrk ; http://lambdaops.com) > > -- Kyle Kelley (@rgbkrk ; http://lambdaops.com) -------------- next part -------------- An HTML attachment was scrubbed... URL: From bussonniermatthias at gmail.com Sat Sep 6 13:02:15 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Sat, 6 Sep 2014 10:02:15 -0700 Subject: [IPython-dev] Jupyter notebook at UC Berkeley Hackathon In-Reply-To: References: Message-ID: <1C9F1A2D-8DB8-456F-832B-0929283021FB@gmail.com> How do we recognize evernote from IPython people and others ? -- M Le 6 sept. 2014 ? 09:51, Kyle Kelley a ?crit : > Never mind, we have snuck in. > > On Saturday, September 6, 2014, Kyle Kelley wrote: > Hey, we don't have key cards and can't make it up the elevator at soda hall. Can you help matthias and I get upstairs? > > On Friday, September 5, 2014, Andrew Chen wrote: > Hello IPython-dev: > > We are currently in a hackathon at UC Berkeley and want to extend the jupyter notebook with new features! > > Over the summer, we've been doing small hacks on the ipython notebooks from writing tools for cross-notebook imports, joystick (xbox controller) widgets, capability for live-tuning control loops, and controlling robots and physical devices. > > If anybody has ideas and suggestions for jupyter notebook that are hurting for implementation, we'd be happy to help. > > We'd also love to have company in the Wozniak Lounge from 10am to 11pm! (tomorrow, 9/6) > > > -- > Kyle Kelley (@rgbkrk; http://lambdaops.com) > > > > -- > Kyle Kelley (@rgbkrk; http://lambdaops.com) > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: From chenjandrew at gmail.com Sat Sep 6 13:07:57 2014 From: chenjandrew at gmail.com (Andrew Chen) Date: Sat, 6 Sep 2014 10:07:57 -0700 Subject: [IPython-dev] Jupyter notebook at UC Berkeley Hackathon In-Reply-To: <1C9F1A2D-8DB8-456F-832B-0929283021FB@gmail.com> References: <1C9F1A2D-8DB8-456F-832B-0929283021FB@gmail.com> Message-ID: I'm sitting in the front by the projector wearing a blue Abbott t-shirt On Sat, Sep 6, 2014 at 10:02 AM, Matthias Bussonnier < bussonniermatthias at gmail.com> wrote: > How do we recognize evernote from IPython people and others ? > -- > M > Le 6 sept. 2014 ? 09:51, Kyle Kelley a ?crit : > > Never mind, we have snuck in. > > On Saturday, September 6, 2014, Kyle Kelley wrote: > >> Hey, we don't have key cards and can't make it up the elevator at soda >> hall. Can you help matthias and I get upstairs? >> >> On Friday, September 5, 2014, Andrew Chen >> wrote: >> >>> Hello IPython-dev: >>> >>> We are currently in a hackathon at UC Berkeley and want to extend the >>> jupyter notebook with new features! >>> >>> Over the summer, we've been doing small hacks on the ipython notebooks >>> from writing tools for cross-notebook imports, joystick (xbox controller) >>> widgets, capability for live-tuning control loops, and controlling robots >>> and physical devices. >>> >>> If anybody has ideas and suggestions for jupyter notebook that are >>> hurting for implementation, we'd be happy to help. >>> >>> We'd also love to have company in the Wozniak Lounge from 10am to 11pm! >>> (tomorrow, 9/6) >>> >> >> >> -- >> Kyle Kelley (@rgbkrk ; http://lambdaops.com) >> >> > > -- > Kyle Kelley (@rgbkrk ; http://lambdaops.com) > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From chenjandrew at gmail.com Sat Sep 6 14:21:06 2014 From: chenjandrew at gmail.com (Andrew Chen) Date: Sat, 6 Sep 2014 11:21:06 -0700 Subject: [IPython-dev] Jupyter notebook at UC Berkeley Hackathon In-Reply-To: References: <1C9F1A2D-8DB8-456F-832B-0929283021FB@gmail.com> Message-ID: robots doing line following: http://nbviewer.ipython.org/github/andrewjchen/topgear/blob/finalcomp/linefollow_test.ipynb random robot demo videos here: http://nbviewer.ipython.org/github/andrewjchen/topgear/blob/finalcomp/demos.ipynb gamepad widget: http://nbviewer.ipython.org/github/andrewjchen/topgear/blob/finalcomp/gamepad_widget.ipynb cross notebook include here: http://nbviewer.ipython.org/github/nikitakit/nbtools/blob/master/nbinclude.ipynb tuning live-running loops: http://nbviewer.ipython.org/gist/nikitakit/b11b4ef2fb67688c5bce We'll post a link to a repo once things ossify.. On Sat, Sep 6, 2014 at 10:07 AM, Andrew Chen wrote: > I'm sitting in the front by the projector wearing a blue Abbott t-shirt > > > On Sat, Sep 6, 2014 at 10:02 AM, Matthias Bussonnier < > bussonniermatthias at gmail.com> wrote: > >> How do we recognize evernote from IPython people and others ? >> -- >> M >> Le 6 sept. 2014 ? 09:51, Kyle Kelley a ?crit : >> >> Never mind, we have snuck in. >> >> On Saturday, September 6, 2014, Kyle Kelley wrote: >> >>> Hey, we don't have key cards and can't make it up the elevator at soda >>> hall. Can you help matthias and I get upstairs? >>> >>> On Friday, September 5, 2014, Andrew Chen >>> wrote: >>> >>>> Hello IPython-dev: >>>> >>>> We are currently in a hackathon at UC Berkeley and want to extend the >>>> jupyter notebook with new features! >>>> >>>> Over the summer, we've been doing small hacks on the ipython notebooks >>>> from writing tools for cross-notebook imports, joystick (xbox controller) >>>> widgets, capability for live-tuning control loops, and controlling robots >>>> and physical devices. >>>> >>>> If anybody has ideas and suggestions for jupyter notebook that are >>>> hurting for implementation, we'd be happy to help. >>>> >>>> We'd also love to have company in the Wozniak Lounge from 10am to 11pm! >>>> (tomorrow, 9/6) >>>> >>> >>> >>> -- >>> Kyle Kelley (@rgbkrk ; http://lambdaops.com) >>> >>> >> >> -- >> Kyle Kelley (@rgbkrk ; http://lambdaops.com) >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From takowl at gmail.com Sat Sep 6 17:57:47 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Sat, 6 Sep 2014 14:57:47 -0700 Subject: [IPython-dev] Flatten notebooks for git diff Message-ID: The notebook document format makes diffing and merging in version control awkward. http://nbdiff.org/ is one attempt to address this by doing rich diffs in the web browser. I've made a simpler approach to diffing only - an nbflatten tool that can be integrated with git diff to display a simplified version of the diff. It discards some information, like metadata and rich output, but the flattened diffs are easier to read for simple changes. The script, and installation instructions, are in a gist: https://gist.github.com/takluyver/bc8f3275c7d34abb68bf This is a very quick hack. Feel free to improve it or work it into bigger things. Thanks, Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: From ssanderson at quantopian.com Sat Sep 6 21:00:40 2014 From: ssanderson at quantopian.com (ssanderson) Date: Sat, 6 Sep 2014 18:00:40 -0700 (PDT) Subject: [IPython-dev] Registering Input Transformers that can Reject Input In-Reply-To: References: <1409929317612-5070376.post@n6.nabble.com> <1409938592373-5070401.post@n6.nabble.com> Message-ID: <1410051640374-5070701.post@n6.nabble.com> PR for this is up at https://github.com/ipython/ipython/pull/6429. -- View this message in context: http://python.6.x6.nabble.com/Registering-Input-Transformers-that-can-Reject-Input-tp5070376p5070701.html Sent from the IPython - Development mailing list archive at Nabble.com. From ocefpaf at gmail.com Sun Sep 7 11:08:32 2014 From: ocefpaf at gmail.com (Filipe Pires Alvarenga Fernandes) Date: Sun, 7 Sep 2014 12:08:32 -0300 Subject: [IPython-dev] Flatten notebooks for git diff In-Reply-To: References: Message-ID: Wonderful! Now I can throw away all my horrible hacks and work around to do exactly that. Thanks! -Filipe On Sat, Sep 6, 2014 at 6:57 PM, Thomas Kluyver wrote: > The notebook document format makes diffing and merging in version control > awkward. http://nbdiff.org/ is one attempt to address this by doing rich > diffs in the web browser. > > I've made a simpler approach to diffing only - an nbflatten tool that can > be integrated with git diff to display a simplified version of the diff. It > discards some information, like metadata and rich output, but the flattened > diffs are easier to read for simple changes. The script, and installation > instructions, are in a gist: > > https://gist.github.com/takluyver/bc8f3275c7d34abb68bf > > This is a very quick hack. Feel free to improve it or work it into bigger > things. > > Thanks, > Thomas > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From mirage007 at gmail.com Sun Sep 7 21:00:06 2014 From: mirage007 at gmail.com (Ivan Zhang) Date: Sun, 7 Sep 2014 21:00:06 -0400 Subject: [IPython-dev] Runtime Console Using IPython In-Reply-To: References: Message-ID: Thanks for the tips, I actually saw that as well while I was making this. My end goal for this tool is to facilitate remote access/monitoring of an application without requiring other users to install something while requiring minimal modification of the original application. 1.I actually think that's one of the keys to the notebook's success. So as the next step, I was interested in exploring how to make a watered down version of ipython's notebook that just had the web console part. Are there any examples of this sort? I tried looking at the notebookapp.py and it just seemed too daunting to dig through. On the other hand, I made a tiny example using BlockingKernelClient ( https://github.com/mirage007/rtconsole/blob/master/rtclient.py) to connect to an instance, but the messages i got back were very verbose. Lastly, as I mentioned in the post, there is an issue where I cannot define functions that uses variables that are supposedly already defined in the user namespace. i.e. in the ipython console, if i type: >>> hello = lambda x: t+ 5 where t was defined in the original application locals() it would give me an error: "global name 't' is not defined" Any idea of how to resolve this? Thanks, -Ivan On Saturday, August 30, 2014, Fernando Perez wrote: > Hi Ivan, > > On Sat, Aug 30, 2014 at 6:36 PM, Ivan Zhang wrote: > >> Hi All, >> >> As a way to familiarize myself with IPython, I wrote a simple tool that >> allows an IPython Kernel to be run as part of a thread, effectively >> creating a way to remotely monitor and change the state of a running >> application in real time. >> > > Great! Thanks for sharing that... I'm sorry that I haven't looked at your > code in detail, but along those lines, I thought at least it would be > useful to point you to these examples: > > https://github.com/ipython/ipython/tree/master/examples/Embedding > > They illustrate how to embed a kernel in a process that may have its own > event loop (Qt and Wx provided), and how to connect to it from an external > Qt console, with both the Qt console and the GUI controls manipulating the > same namespace. > > It's a different take on the same kind of ideas, and you may find it > useful. > > Cheers > > f > -------------- next part -------------- An HTML attachment was scrubbed... URL: From takowl at gmail.com Sun Sep 7 21:25:10 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Sun, 7 Sep 2014 18:25:10 -0700 Subject: [IPython-dev] Runtime Console Using IPython In-Reply-To: References: Message-ID: You set shell.user_ns after initialising the kernel (and hence the InteractiveShell object). Try passing in the namespace as user_ns when you instantiate the kernel. Thomas On 7 September 2014 18:00, Ivan Zhang wrote: > Thanks for the tips, I actually saw that as well while I was making this. > My end goal for this tool is to facilitate remote access/monitoring of an > application without requiring other users to install something while > requiring minimal modification of the original application. > > 1.I actually think that's one of the keys to the notebook's success. So as > the next step, I was interested in exploring how to make a watered down > version of ipython's notebook that just had the web console part. Are there > any examples of this sort? > > I tried looking at the notebookapp.py and it just seemed too daunting to > dig through. On the other hand, I made a tiny example using > BlockingKernelClient ( > https://github.com/mirage007/rtconsole/blob/master/rtclient.py) > to connect to an instance, but the messages i got back were very verbose. > > Lastly, as I mentioned in the post, there is an issue where I cannot > define functions that uses variables that are supposedly already defined in > the user namespace. > > i.e. in the ipython console, if i type: > > >>> hello = lambda x: t+ 5 > > where t was defined in the original application locals() > > it would give me an error: > > "global name 't' is not defined" > > Any idea of how to resolve this? > > Thanks, > > -Ivan > > On Saturday, August 30, 2014, Fernando Perez wrote: > >> Hi Ivan, >> >> On Sat, Aug 30, 2014 at 6:36 PM, Ivan Zhang wrote: >> >>> Hi All, >>> >>> As a way to familiarize myself with IPython, I wrote a simple tool that >>> allows an IPython Kernel to be run as part of a thread, effectively >>> creating a way to remotely monitor and change the state of a running >>> application in real time. >>> >> >> Great! Thanks for sharing that... I'm sorry that I haven't looked at your >> code in detail, but along those lines, I thought at least it would be >> useful to point you to these examples: >> >> https://github.com/ipython/ipython/tree/master/examples/Embedding >> >> They illustrate how to embed a kernel in a process that may have its own >> event loop (Qt and Wx provided), and how to connect to it from an external >> Qt console, with both the Qt console and the GUI controls manipulating the >> same namespace. >> >> It's a different take on the same kind of ideas, and you may find it >> useful. >> >> Cheers >> >> f >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From a.h.jaffe at gmail.com Mon Sep 8 07:16:15 2014 From: a.h.jaffe at gmail.com (Andrew Jaffe) Date: Mon, 08 Sep 2014 12:16:15 +0100 Subject: [IPython-dev] nbconvert Slides: latex and images Message-ID: <540D8FFF.9030908@gmail.com> Hi all, I can set up a slide-show using Fernando Perez's tools from https://github.com/fperez/nb-slideshow-template These work fine, but I like the look (and finer control) of the nbconvert --to slides --post serve version. However, I don't seem to be able to get mathjax or tags to work when serving the slides this way. Any ideas? Yours, Andrew p.s. Also, in general, the documentation for all of these things doesn't seem to be completely synced with the actual production version of ipython. From damianavila at gmail.com Mon Sep 8 09:09:07 2014 From: damianavila at gmail.com (=?UTF-8?Q?Dami=C3=A1n_Avila?=) Date: Mon, 8 Sep 2014 10:09:07 -0300 Subject: [IPython-dev] nbconvert Slides: latex and images In-Reply-To: <540D8FFF.9030908@gmail.com> References: <540D8FFF.9030908@gmail.com> Message-ID: Regarding the nbconverted generated slides, if you are using master, some weeks ago mathjax changes the CDN url, so the html and the slides options in nbconvert were affected. Currently on master, the problem is solved... Regarding the images, do you have a minimal example notebook to investigate why is not rendering? And, the documentation is probably outdated, but let me know specifically which part caused you problem. Cheers. 2014-09-08 8:16 GMT-03:00 Andrew Jaffe : > Hi all, > > I can set up a slide-show using Fernando Perez's tools from > https://github.com/fperez/nb-slideshow-template > > These work fine, but I like the look (and finer control) of the > nbconvert --to slides --post serve > version. > > However, I don't seem to be able to get mathjax or tags to work > when serving the slides this way. Any ideas? > > Yours, > > Andrew > > p.s. Also, in general, the documentation for all of these things doesn't > seem to be completely synced with the actual production version of ipython. > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -- *Dami?n* -------------- next part -------------- An HTML attachment was scrubbed... URL: From damontallen at gmail.com Mon Sep 8 10:28:28 2014 From: damontallen at gmail.com (Damon Allen) Date: Mon, 8 Sep 2014 10:28:28 -0400 Subject: [IPython-dev] nbconvert Slides: latex and images In-Reply-To: References: <540D8FFF.9030908@gmail.com> Message-ID: Dami?n, Should this change in mathjax have affected existing slides online? I've just had a student report to me that slides like this one are not rendering Latex equations. I haven't been running master for lecture material development in my class for stability reasons. Is there a flag setting that will allow me to use nbconvert with version 2.2 to fix this? Thanks, Damon On Mon, Sep 8, 2014 at 9:09 AM, Dami?n Avila wrote: > Regarding the nbconverted generated slides, if you are using master, some > weeks ago mathjax changes the CDN url, so the html and the slides options > in nbconvert were affected. Currently on master, the problem is solved... > > Regarding the images, do you have a minimal example notebook to > investigate why is not rendering? > > And, the documentation is probably outdated, but let me know specifically > which part caused you problem. > > Cheers. > > 2014-09-08 8:16 GMT-03:00 Andrew Jaffe : > > Hi all, >> >> I can set up a slide-show using Fernando Perez's tools from >> https://github.com/fperez/nb-slideshow-template >> >> These work fine, but I like the look (and finer control) of the >> nbconvert --to slides --post serve >> version. >> >> However, I don't seem to be able to get mathjax or tags to work >> when serving the slides this way. Any ideas? >> >> Yours, >> >> Andrew >> >> p.s. Also, in general, the documentation for all of these things doesn't >> seem to be completely synced with the actual production version of >> ipython. >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> > > > > -- > *Dami?n* > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From damianavila at gmail.com Mon Sep 8 10:48:01 2014 From: damianavila at gmail.com (=?UTF-8?Q?Dami=C3=A1n_Avila?=) Date: Mon, 8 Sep 2014 11:48:01 -0300 Subject: [IPython-dev] nbconvert Slides: latex and images In-Reply-To: References: <540D8FFF.9030908@gmail.com> Message-ID: Damon, yes, it will affect existing slides because all are pointing to the old CDN... An easy way to temporarily fix the issue is to use a custom templates with the correct url... Just download this templates in the same folder where your ipynb lives: https://gist.github.com/damianavila/ba6a308bd0e605db0e6e and run: ipython nconvert --to slides --post serve --template slides.tpl Hope it helps. Damian 2014-09-08 11:28 GMT-03:00 Damon Allen : > Dami?n, > > Should this change in mathjax have affected existing slides online? I've > just had a student report to me that slides like this one > > are not rendering Latex equations. I haven't been running master for > lecture material development in my class for stability reasons. Is there a > flag setting that will allow me to use nbconvert with version 2.2 to fix > this? > > Thanks, > Damon > > On Mon, Sep 8, 2014 at 9:09 AM, Dami?n Avila > wrote: > >> Regarding the nbconverted generated slides, if you are using master, some >> weeks ago mathjax changes the CDN url, so the html and the slides options >> in nbconvert were affected. Currently on master, the problem is solved... >> >> Regarding the images, do you have a minimal example notebook to >> investigate why is not rendering? >> >> And, the documentation is probably outdated, but let me know specifically >> which part caused you problem. >> >> Cheers. >> >> 2014-09-08 8:16 GMT-03:00 Andrew Jaffe : >> >> Hi all, >>> >>> I can set up a slide-show using Fernando Perez's tools from >>> https://github.com/fperez/nb-slideshow-template >>> >>> These work fine, but I like the look (and finer control) of the >>> nbconvert --to slides --post serve >>> version. >>> >>> However, I don't seem to be able to get mathjax or tags to work >>> when serving the slides this way. Any ideas? >>> >>> Yours, >>> >>> Andrew >>> >>> p.s. Also, in general, the documentation for all of these things doesn't >>> seem to be completely synced with the actual production version of >>> ipython. >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >> >> >> >> -- >> *Dami?n* >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- *Dami?n* -------------- next part -------------- An HTML attachment was scrubbed... URL: From damontallen at gmail.com Mon Sep 8 11:59:47 2014 From: damontallen at gmail.com (Damon Allen) Date: Mon, 8 Sep 2014 11:59:47 -0400 Subject: [IPython-dev] nbconvert Slides: latex and images In-Reply-To: References: <540D8FFF.9030908@gmail.com> Message-ID: Thanks! That did it. On Mon, Sep 8, 2014 at 10:48 AM, Dami?n Avila wrote: > Damon, yes, it will affect existing slides because all are pointing to the > old CDN... > An easy way to temporarily fix the issue is to use a custom templates with > the correct url... > > Just download this templates in the same folder where your ipynb lives: > > https://gist.github.com/damianavila/ba6a308bd0e605db0e6e > > and run: > > ipython nconvert --to slides --post serve --template slides.tpl > > Hope it helps. > > Damian > > > 2014-09-08 11:28 GMT-03:00 Damon Allen : > > Dami?n, >> >> Should this change in mathjax have affected existing slides online? I've >> just had a student report to me that slides like this one >> >> are not rendering Latex equations. I haven't been running master for >> lecture material development in my class for stability reasons. Is there a >> flag setting that will allow me to use nbconvert with version 2.2 to fix >> this? >> >> Thanks, >> Damon >> >> On Mon, Sep 8, 2014 at 9:09 AM, Dami?n Avila >> wrote: >> >>> Regarding the nbconverted generated slides, if you are using master, >>> some weeks ago mathjax changes the CDN url, so the html and the slides >>> options in nbconvert were affected. Currently on master, the problem is >>> solved... >>> >>> Regarding the images, do you have a minimal example notebook to >>> investigate why is not rendering? >>> >>> And, the documentation is probably outdated, but let me know >>> specifically which part caused you problem. >>> >>> Cheers. >>> >>> 2014-09-08 8:16 GMT-03:00 Andrew Jaffe : >>> >>> Hi all, >>>> >>>> I can set up a slide-show using Fernando Perez's tools from >>>> https://github.com/fperez/nb-slideshow-template >>>> >>>> These work fine, but I like the look (and finer control) of the >>>> nbconvert --to slides --post serve >>>> version. >>>> >>>> However, I don't seem to be able to get mathjax or tags to work >>>> when serving the slides this way. Any ideas? >>>> >>>> Yours, >>>> >>>> Andrew >>>> >>>> p.s. Also, in general, the documentation for all of these things doesn't >>>> seem to be completely synced with the actual production version of >>>> ipython. >>>> _______________________________________________ >>>> IPython-dev mailing list >>>> IPython-dev at scipy.org >>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>> >>> >>> >>> >>> -- >>> *Dami?n* >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > > -- > *Dami?n* > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From takowl at gmail.com Mon Sep 8 12:43:11 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Mon, 8 Sep 2014 09:43:11 -0700 Subject: [IPython-dev] Plans for splitting up IPython Message-ID: One of the big topics at our in-person development meeting last week was how we're going to separate IPython into a number of smaller components, and transition some of those to the new name Jupyter. We want to keep people who weren't there in the loop about this plan. IPython 3.0 will hopefully be released some time this Autumn, and the 3.x releases will remain as one big 'ipython' package with optional dependencies for components like the notebook and the Qt console. Some time after the release of 3.0, we'll start separating pieces out into separate repositories. By 4.0, we hope to have eight pieces to release separately: - One base package with the traitlets, config and application machinery, to be used by other components. - Two API packages: one for reading and writing the notebook file format, and one for controlling and communicating with kernels. - Three frontend applications: the notebook, Qt console and two-process terminal console. - The remaining 'ipython' package, which will include the IPython kernel and the single-process terminal REPL. The attached photo shows this separation as we sketched it out on a whiteboard. Later on, we might further separate components, like splitting nbconvert out of the notebook application package, but we think making these 8 pieces will be quite enough for now. The transition will involve a lot of extra work, but we're satisfied that it will be worth it. Separating these components more cleanly should allow the individual pieces to be developed more rapidly by more contributors. This is also when we'll start using the name Jupyter. The Python specific IPython package will keep its own name, while all the other packages (which are neutral to the kernel language) will have Jupyter in their names. Thanks, Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: ipython_separation_whiteboard.jpg Type: image/jpeg Size: 107252 bytes Desc: not available URL: From rgbkrk at gmail.com Mon Sep 8 15:19:31 2014 From: rgbkrk at gmail.com (Kyle Kelley) Date: Mon, 8 Sep 2014 14:19:31 -0500 Subject: [IPython-dev] Indexing Jupyter Notebooks Message-ID: Hey IPythonistas, Jovians, and friends, Before our IPython development meeting this past week (on the plane to SFO actually), we started experimenting with indexing Jupyter notebooks using ElasticSearch. The notebooks are JSON which ElasticSearch can handle directly: # pip install elasticsearch requests import elasticsearch import requests es = elasticsearch.Elasticsearch([{'host':"127.0.0.1" 'port':9200]) resp = requests.get("http://bit.ly/lorenzsystem") notebook_contents = resp.json() resp = es.index(index='notebooks', doc_type='ipynb', body=notebook_contents) The current setup in the notebook viewer can be viewed (or hacked on) via https://github.com/ipython/nbviewer/blob/568ae74c9b8a74f7b24cac271b6b1fbdd1c42643/nbviewer/index.py#L34-L48 . Announcing this at the development meetings got a lot of discussion going. *Potential Utility of Indexing Notebooks* - Searching notebooks with plain old raw text search - Searching notebooks using the actual notebook structure (by language, cell types, etc.) - Streaming feed of notebooks being "created" - Galleries of plots - Using code cells to build models for code completion - Trending notebooks (* don't actually need a full notebook index for this) - Corpus of structured scholarly works (for some value of scholarly) Though Notebook Viewer only handles publicly accessible notebooks, including secret gists, this does bring up some privacy concerns. *Privacy Concerns* What notebooks can we expose through a search interface or API? Do we need to obey the robots.txt for each site? What about notebooks on GitHub? Do we use some robots.txt scheme? They're searchable on GitHub already. There was even more brought up during the dev meetings, but we'd like to hear from everyone within the IPython/Jupyter community. *Current Plans* Currently we're indexing notebooks to see what running elasticsearch nodes is like and determine our infrastructure needs. We're not exposing the data or the elasticsearch node for the time being. In fact, the current node that is indexing will be torn down shortly. It was a good experiment, but needs tweaking to be done in practice. We've at least determined that we need separate storage of - Embedded images - Static widgets We're currently thinking these should be referenced by UUID and either go to an object store (for us, Rackspace CloudFiles) or a database. Dumping an entire notebook as is into the notebook index actually doesn't lend well to searching the notebook natively (we would need to index specific fields, not make nested queries). I really need to understand ElasticSearch more fully as well, as I only started with it last week. Would love to hear your thoughts on all of this. Cheers, Kyle Kelley P.S. See http://en.wikipedia.org/wiki/Jovian_(fiction) for why I said Jovians up top. ;) -- Kyle Kelley (@rgbkrk ; http://lambdaops.com) -------------- next part -------------- An HTML attachment was scrubbed... URL: From doug.blank at gmail.com Mon Sep 8 16:15:22 2014 From: doug.blank at gmail.com (Doug Blank) Date: Mon, 8 Sep 2014 16:15:22 -0400 Subject: [IPython-dev] Indexing Jupyter Notebooks In-Reply-To: References: Message-ID: Kyle, These ideas are great, and hope to see more work along these lines! I've been running the jupyterhub for one of my classes since last week, and it working very well. (If the project "jupyterhub" is new to those reading this, it is IPython's server-based access to notebooks. Similar to wakari or Sage Math Cloud, but on my own server. Students log in via the web, and have regular access to the computer. I'm running on Ubuntu 14.10 at http://jupyter.cs.brynmawr.edu/ if you want to see the bare bones look right now. There are bugs and limitations.) Almost immediately, there were a large number of notebooks to keep track of... some that have help documentation, others that have examples, and others in various languages. And the students have created a bunch of their own (86 notebooks in one week). What would be cool would be an API for creating support functions for a "collection of notebooks"... whether they are just a folder on your harddrive, a jupyterhub server, or a collection of distributed notebook via their URLs (like you have with nbviewer), it would be wonderful to have a variety of functions: * search (including by json structure) * lists/search available by: how many times viewed, date (eg, latest), most up-voted, topic (eg, Physics), organization, author * tag cloud * dynamic sitemap Basically, anything that Drupal or Wordpress have thought of, it would be useful for a collection of notebooks. Tweak jupyterhub a bit and you have a notebook-based blog, wiki, class website, or on-line journal. So, I have little knowledge of what technology would be useful for implementing indexing, but just hoping that whatever you create can be used in a way that supports these kinds of uses. It would great to be able to drop a search module into jupyterhub, maybe configure it the way that Django or Tornado do with plugins, and have it appear as a panel on the main webpage. As for privacy for nbviewer: yes, you should probably respect robots.txt. Github and the like would seem to be fair game (perhaps unless they have some "noindex" flag in their metadata.) Thanks! -Doug On Mon, Sep 8, 2014 at 3:19 PM, Kyle Kelley wrote: > Hey IPythonistas, Jovians, and friends, > > Before our IPython development meeting this past week (on the plane to SFO > actually), we started experimenting with indexing Jupyter notebooks using > ElasticSearch. > > The notebooks are JSON which ElasticSearch can handle directly: > > # pip install elasticsearch requests > import elasticsearch > import requests > > es = elasticsearch.Elasticsearch([{'host':"127.0.0.1" 'port':9200]) > > resp = requests.get("http://bit.ly/lorenzsystem") > notebook_contents = resp.json() > > resp = es.index(index='notebooks', > doc_type='ipynb', > body=notebook_contents) > > > The current setup in the notebook viewer can be viewed (or hacked on) via > https://github.com/ipython/nbviewer/blob/568ae74c9b8a74f7b24cac271b6b1fbdd1c42643/nbviewer/index.py#L34-L48 > . > > Announcing this at the development meetings got a lot of discussion going. > > *Potential Utility of Indexing Notebooks* > > - Searching notebooks with plain old raw text search > - Searching notebooks using the actual notebook structure (by > language, cell types, etc.) > - Streaming feed of notebooks being "created" > - Galleries of plots > - Using code cells to build models for code completion > - Trending notebooks (* don't actually need a full notebook index for > this) > - Corpus of structured scholarly works (for some value of scholarly) > > Though Notebook Viewer only handles publicly accessible notebooks, > including secret gists, this does bring up some privacy concerns. > > *Privacy Concerns* > > What notebooks can we expose through a search interface or API? > > Do we need to obey the robots.txt for each site? > > What about notebooks on GitHub? Do we use some robots.txt scheme? They're > searchable on GitHub already. > > There was even more brought up during the dev meetings, but we'd like to > hear from everyone within the IPython/Jupyter community. > > *Current Plans* > > Currently we're indexing notebooks to see what running elasticsearch nodes > is like and determine our infrastructure needs. We're not exposing the data > or the elasticsearch node for the time being. In fact, the current node > that is indexing will be torn down shortly. It was a good experiment, but > needs tweaking to be done in practice. > > We've at least determined that we need separate storage of > > - Embedded images > - Static widgets > > We're currently thinking these should be referenced by UUID and either go > to an object store (for us, Rackspace CloudFiles) or a database. > > Dumping an entire notebook as is into the notebook index actually doesn't > lend well to searching the notebook natively (we would need to index > specific fields, not make nested queries). I really need to understand > ElasticSearch more fully as well, as I only started with it last week. > > Would love to hear your thoughts on all of this. > > Cheers, > > Kyle Kelley > > > P.S. See http://en.wikipedia.org/wiki/Jovian_(fiction) for why I said > Jovians up top. ;) > > -- > Kyle Kelley (@rgbkrk ; http://lambdaops.com) > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From fperez.net at gmail.com Mon Sep 8 17:33:13 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Mon, 8 Sep 2014 14:33:13 -0700 Subject: [IPython-dev] Flatten notebooks for git diff In-Reply-To: References: Message-ID: On Sat, Sep 6, 2014 at 2:57 PM, Thomas Kluyver wrote: > The notebook document format makes diffing and merging in version control > awkward. http://nbdiff.org/ is one attempt to address this by doing rich > diffs in the web browser. > > I've made a simpler approach to diffing only - an nbflatten tool that can > be integrated with git diff to display a simplified version of the diff. It > discards some information, like metadata and rich output, but the flattened > diffs are easier to read for simple changes. The script, and installation > instructions, are in a gist: > > https://gist.github.com/takluyver/bc8f3275c7d34abb68bf > > This is a very quick hack. Feel free to improve it or work it into bigger > things. > I just wanted to say this is *great*. It's an excellent, practical solution that will cover a ton of everyday cases. One thought: perhaps also enabiling it as a standalone `git nbdiff` command, that can take extra switches for metadata and other things... So it would do the bare-bones thing when called by git itself during a diff of an entire repo, but could be used in a more targeted and feature-rich manner manually... In any case, thanks! f -------------- next part -------------- An HTML attachment was scrubbed... URL: From nathan12343 at gmail.com Mon Sep 8 17:43:00 2014 From: nathan12343 at gmail.com (Nathan Goldbaum) Date: Mon, 8 Sep 2014 14:43:00 -0700 Subject: [IPython-dev] Flatten notebooks for git diff In-Reply-To: References: Message-ID: On Mon, Sep 8, 2014 at 2:33 PM, Fernando Perez wrote: > On Sat, Sep 6, 2014 at 2:57 PM, Thomas Kluyver wrote: > >> The notebook document format makes diffing and merging in version control >> awkward. http://nbdiff.org/ is one attempt to address this by doing rich >> diffs in the web browser. >> >> I've made a simpler approach to diffing only - an nbflatten tool that can >> be integrated with git diff to display a simplified version of the diff. It >> discards some information, like metadata and rich output, but the flattened >> diffs are easier to read for simple changes. The script, and installation >> instructions, are in a gist: >> >> https://gist.github.com/takluyver/bc8f3275c7d34abb68bf >> >> This is a very quick hack. Feel free to improve it or work it into bigger >> things. >> > > I just wanted to say this is *great*. It's an excellent, practical > solution that will cover a ton of everyday cases. > > One thought: perhaps also enabiling it as a standalone `git nbdiff` > command, that can take extra switches for metadata and other things... So > it would do the bare-bones thing when called by git itself during a diff of > an entire repo, but could be used in a more targeted and feature-rich > manner manually... > Or even a standalone shell script - this will make it easier to use with the mercurial extdiff extension. > > In any case, thanks! > > f > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From takowl at gmail.com Mon Sep 8 18:17:46 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Mon, 8 Sep 2014 15:17:46 -0700 Subject: [IPython-dev] Flatten notebooks for git diff In-Reply-To: References: Message-ID: >From what I can see, Mercurial requires you to specify a diff program. This is particularly convenient with git, because it allows you to specify a filter to process a single file, and then diffs the results for you. Of course, it would be easy to wrap this up together with diff. Thomas On 8 September 2014 14:43, Nathan Goldbaum wrote: > > > On Mon, Sep 8, 2014 at 2:33 PM, Fernando Perez > wrote: > >> On Sat, Sep 6, 2014 at 2:57 PM, Thomas Kluyver wrote: >> >>> The notebook document format makes diffing and merging in version >>> control awkward. http://nbdiff.org/ is one attempt to address this by >>> doing rich diffs in the web browser. >>> >>> I've made a simpler approach to diffing only - an nbflatten tool that >>> can be integrated with git diff to display a simplified version of the >>> diff. It discards some information, like metadata and rich output, but the >>> flattened diffs are easier to read for simple changes. The script, and >>> installation instructions, are in a gist: >>> >>> https://gist.github.com/takluyver/bc8f3275c7d34abb68bf >>> >>> This is a very quick hack. Feel free to improve it or work it into >>> bigger things. >>> >> >> I just wanted to say this is *great*. It's an excellent, practical >> solution that will cover a ton of everyday cases. >> >> One thought: perhaps also enabiling it as a standalone `git nbdiff` >> command, that can take extra switches for metadata and other things... So >> it would do the bare-bones thing when called by git itself during a diff of >> an entire repo, but could be used in a more targeted and feature-rich >> manner manually... >> > > Or even a standalone shell script - this will make it easier to use with > the mercurial extdiff extension. > > >> >> In any case, thanks! >> >> f >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From mirage007 at gmail.com Mon Sep 8 20:34:46 2014 From: mirage007 at gmail.com (Ivan Zhang) Date: Mon, 8 Sep 2014 20:34:46 -0400 Subject: [IPython-dev] Runtime Console Using IPython In-Reply-To: References: Message-ID: Nice, that worked, thanks! On Sun, Sep 7, 2014 at 9:25 PM, Thomas Kluyver wrote: > You set shell.user_ns after initialising the kernel (and hence the > InteractiveShell object). Try passing in the namespace as user_ns when you > instantiate the kernel. > > Thomas > > On 7 September 2014 18:00, Ivan Zhang wrote: > >> Thanks for the tips, I actually saw that as well while I was making this. >> My end goal for this tool is to facilitate remote access/monitoring of an >> application without requiring other users to install something while >> requiring minimal modification of the original application. >> >> 1.I actually think that's one of the keys to the notebook's success. So >> as the next step, I was interested in exploring how to make a watered down >> version of ipython's notebook that just had the web console part. Are there >> any examples of this sort? >> >> I tried looking at the notebookapp.py and it just seemed too daunting to >> dig through. On the other hand, I made a tiny example using >> BlockingKernelClient ( >> https://github.com/mirage007/rtconsole/blob/master/rtclient.py) >> to connect to an instance, but the messages i got back were very verbose. >> >> Lastly, as I mentioned in the post, there is an issue where I cannot >> define functions that uses variables that are supposedly already defined in >> the user namespace. >> >> i.e. in the ipython console, if i type: >> >> >>> hello = lambda x: t+ 5 >> >> where t was defined in the original application locals() >> >> it would give me an error: >> >> "global name 't' is not defined" >> >> Any idea of how to resolve this? >> >> Thanks, >> >> -Ivan >> >> On Saturday, August 30, 2014, Fernando Perez >> wrote: >> >>> Hi Ivan, >>> >>> On Sat, Aug 30, 2014 at 6:36 PM, Ivan Zhang wrote: >>> >>>> Hi All, >>>> >>>> As a way to familiarize myself with IPython, I wrote a simple tool that >>>> allows an IPython Kernel to be run as part of a thread, effectively >>>> creating a way to remotely monitor and change the state of a running >>>> application in real time. >>>> >>> >>> Great! Thanks for sharing that... I'm sorry that I haven't looked at >>> your code in detail, but along those lines, I thought at least it would be >>> useful to point you to these examples: >>> >>> https://github.com/ipython/ipython/tree/master/examples/Embedding >>> >>> They illustrate how to embed a kernel in a process that may have its own >>> event loop (Qt and Wx provided), and how to connect to it from an external >>> Qt console, with both the Qt console and the GUI controls manipulating the >>> same namespace. >>> >>> It's a different take on the same kind of ideas, and you may find it >>> useful. >>> >>> Cheers >>> >>> f >>> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- Ivan -------------- next part -------------- An HTML attachment was scrubbed... URL: From a.kurosawa at gmail.com Tue Sep 9 04:12:28 2014 From: a.kurosawa at gmail.com (David Bernal) Date: Tue, 9 Sep 2014 10:12:28 +0200 Subject: [IPython-dev] nbconverter exports display latex code instead of math formulas Message-ID: Hi I'm beginning to use iPython Notebook on Chrome in a mac os X 10.9. everything displays normally in the notebook, but when I export it with nbconvert instead of diplaying the math text written in latex it shows the latex code. I dont really know if its a problem of chrome, nbconvert, my os or something I hadnt installed correctly. Any help? -------------- next part -------------- An HTML attachment was scrubbed... URL: From bussonniermatthias at gmail.com Tue Sep 9 05:10:51 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Tue, 9 Sep 2014 11:10:51 +0200 Subject: [IPython-dev] nbconverter exports display latex code instead of math formulas In-Reply-To: References: Message-ID: Hi, Please have a look at mailing list archive. http://mail.scipy.org/pipermail/ipython-dev/2014-September/thread.html If the information there did not work for you, can you include what you have tried so that we can narrow the problem. Thanks. Envoy? de mon iPhone > Le 9 sept. 2014 ? 10:12, David Bernal a ?crit : > > Hi I'm beginning to use iPython Notebook on Chrome in a mac os X 10.9. everything displays normally in the notebook, but when I export it with nbconvert instead of diplaying the math text written in latex it shows the latex code. I dont really know if its a problem of chrome, nbconvert, my os or something I hadnt installed correctly. Any help? > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: From a.h.jaffe at gmail.com Tue Sep 9 09:33:20 2014 From: a.h.jaffe at gmail.com (Andrew Jaffe) Date: Tue, 09 Sep 2014 14:33:20 +0100 Subject: [IPython-dev] nbconvert Slides: latex and images In-Reply-To: References: <540D8FFF.9030908@gmail.com> Message-ID: <540F01A0.9080302@gmail.com> Hi Dami?n, Thanks for the response. On 08/09/2014 14:09, Dami?n Avila wrote: > Regarding the nbconverted generated slides, if you are using master, > some weeks ago mathjax changes the CDN url, so the html and the slides > options in nbconvert were affected. Currently on master, the problem is > solved... Thanks -- the template gist you posted works great. Is there any way to run MathJax locally? > Regarding the images, do you have a minimal example notebook to > investigate why is not rendering? It seems to occur because I was storing the images in a subdirectory. If I replace with (and move the files!) it works. > > And, the documentation is probably outdated, but let me know > specifically which part caused you problem. I'll try to have a look if I get the chance. Andrew > > Cheers. > > 2014-09-08 8:16 GMT-03:00 Andrew Jaffe >: > > Hi all, > > I can set up a slide-show using Fernando Perez's tools from > https://github.com/fperez/nb-slideshow-template > > These work fine, but I like the look (and finer control) of the > nbconvert --to slides --post serve > version. > > However, I don't seem to be able to get mathjax or tags to work > when serving the slides this way. Any ideas? > > Yours, > > Andrew > > p.s. Also, in general, the documentation for all of these things doesn't > seem to be completely synced with the actual production version of > ipython. From erik.m.bray at gmail.com Tue Sep 9 12:49:43 2014 From: erik.m.bray at gmail.com (Erik Bray) Date: Tue, 9 Sep 2014 12:49:43 -0400 Subject: [IPython-dev] IPython inputhook, higher rate? In-Reply-To: References: Message-ID: On Thu, Sep 4, 2014 at 12:34 PM, Gustavo Goretkin wrote: > > ---------- Forwarded message ---------- > From: Gustavo Goretkin > Date: Thu, Aug 28, 2014 at 1:25 PM > Subject: IPython inputhook, higher rate? > To: ipython-user at scipy.org > > > I'm using IPython.lib.inputhook to run steps in a simulation (Box2D and > pygame, which uses sdl). When I run this step in my own loop, I can get many > hundred of Hertz. When I use set_inputhook, I can only get 8 Hz. When > IPython is integrated with GUI backends (like any of the matplotlib > interactive backends), it's very responsive. Is there a setting I'm missing? > > Thank you! > Gustavo > > > >> def run_from_ipython(): >> try: >> __IPYTHON__ >> return True >> except NameError: >> return False >> >> if not run_from_ipython(): >> while domain.running: >> domain.run_step() >> else: >> from IPython.lib import inputhook >> >> def step(): >> domain.run_step() >> return domain.running >> >> inputhook.set_inputhook(step) Hi Gustavo, I was interested by your email, so I tried reproducing the problem with a simple pygame game and encountered the same issue. Not sure what's going on yet though. The only reference to this I found was this message from Fernando some 7 years ago :( http://mail.scipy.org/pipermail/ipython-dev/2007-November/003333.html Sounds like there were problems though. I don't know if anyone else has resolved them. Erik From erik.m.bray at gmail.com Tue Sep 9 13:03:11 2014 From: erik.m.bray at gmail.com (Erik Bray) Date: Tue, 9 Sep 2014 13:03:11 -0400 Subject: [IPython-dev] IPython inputhook, higher rate? In-Reply-To: References: Message-ID: On Tue, Sep 9, 2014 at 12:49 PM, Erik Bray wrote: > On Thu, Sep 4, 2014 at 12:34 PM, Gustavo Goretkin > wrote: >> >> ---------- Forwarded message ---------- >> From: Gustavo Goretkin >> Date: Thu, Aug 28, 2014 at 1:25 PM >> Subject: IPython inputhook, higher rate? >> To: ipython-user at scipy.org >> >> >> I'm using IPython.lib.inputhook to run steps in a simulation (Box2D and >> pygame, which uses sdl). When I run this step in my own loop, I can get many >> hundred of Hertz. When I use set_inputhook, I can only get 8 Hz. When >> IPython is integrated with GUI backends (like any of the matplotlib >> interactive backends), it's very responsive. Is there a setting I'm missing? >> >> Thank you! >> Gustavo >> >> >> >>> def run_from_ipython(): >>> try: >>> __IPYTHON__ >>> return True >>> except NameError: >>> return False >>> >>> if not run_from_ipython(): >>> while domain.running: >>> domain.run_step() >>> else: >>> from IPython.lib import inputhook >>> >>> def step(): >>> domain.run_step() >>> return domain.running >>> >>> inputhook.set_inputhook(step) > > Hi Gustavo, > > I was interested by your email, so I tried reproducing the problem > with a simple pygame game and encountered the same issue. Not sure > what's going on yet though. The only reference to this I found was > this message from Fernando some 7 years ago :( > > http://mail.scipy.org/pipermail/ipython-dev/2007-November/003333.html > > Sounds like there were problems though. I don't know if anyone else > has resolved them. My guess is that an inputhook handler for SDL similar to the pyglet inputhook might be necessary: https://github.com/ipython/ipython/blob/825f3e480e9d9e4032abab7bc72e5cd086cc3e89/IPython/lib/inputhookpyglet.py I don't have any more time too look into it right now though. Erik From fperez.net at gmail.com Tue Sep 9 13:07:21 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Tue, 9 Sep 2014 10:07:21 -0700 Subject: [IPython-dev] IPython inputhook, higher rate? In-Reply-To: References: Message-ID: On Tue, Sep 9, 2014 at 10:03 AM, Erik Bray wrote: > My guess is that an inputhook handler for SDL similar to the pyglet > inputhook might be necessary: > > > https://github.com/ipython/ipython/blob/825f3e480e9d9e4032abab7bc72e5cd086cc3e89/IPython/lib/inputhookpyglet.py > Yup, good guess. I suspect the solution is along those lines too. > I don't have any more time too look into it right now though. > Sadly, most of us in the core team are in the same boat. If someone can put together a well-tested PR that solves the problem for them, we can probably merge it relatively quickly. These things are typically a small amount of code, but they require patience to get right and lots of live, interactive testing. We can't do that right now on this topic, but a clean PR where someone has done all that leg work would likely not be too hard to merge. Cheers, f -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: From fperez.net at gmail.com Tue Sep 9 13:10:19 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Tue, 9 Sep 2014 10:10:19 -0700 Subject: [IPython-dev] Jupyter notebook at UC Berkeley Hackathon In-Reply-To: References: <1C9F1A2D-8DB8-456F-832B-0929283021FB@gmail.com> Message-ID: Hi Andrew, I'm sorry I couldn't come in person to the hackathon, but I heard from Thomas and the others about what you guys were doing. I'm thrilled to hear that some of our students are putting time into the project! Hopefully we can meet your team sometime later this fall on campus, and get you guys more involved with IPython. Just drop me a line on my campus address and we can find a time to grab a bite or a coffee. Best, f On Sat, Sep 6, 2014 at 11:21 AM, Andrew Chen wrote: > robots doing line following: > > http://nbviewer.ipython.org/github/andrewjchen/topgear/blob/finalcomp/linefollow_test.ipynb > > random robot demo videos here: > > http://nbviewer.ipython.org/github/andrewjchen/topgear/blob/finalcomp/demos.ipynb > > gamepad widget: > > http://nbviewer.ipython.org/github/andrewjchen/topgear/blob/finalcomp/gamepad_widget.ipynb > > cross notebook include here: > > http://nbviewer.ipython.org/github/nikitakit/nbtools/blob/master/nbinclude.ipynb > > tuning live-running loops: > http://nbviewer.ipython.org/gist/nikitakit/b11b4ef2fb67688c5bce > > We'll post a link to a repo once things ossify.. > > > > On Sat, Sep 6, 2014 at 10:07 AM, Andrew Chen > wrote: > >> I'm sitting in the front by the projector wearing a blue Abbott t-shirt >> >> >> On Sat, Sep 6, 2014 at 10:02 AM, Matthias Bussonnier < >> bussonniermatthias at gmail.com> wrote: >> >>> How do we recognize evernote from IPython people and others ? >>> -- >>> M >>> Le 6 sept. 2014 ? 09:51, Kyle Kelley a ?crit : >>> >>> Never mind, we have snuck in. >>> >>> On Saturday, September 6, 2014, Kyle Kelley wrote: >>> >>>> Hey, we don't have key cards and can't make it up the elevator at soda >>>> hall. Can you help matthias and I get upstairs? >>>> >>>> On Friday, September 5, 2014, Andrew Chen >>>> wrote: >>>> >>>>> Hello IPython-dev: >>>>> >>>>> We are currently in a hackathon at UC Berkeley and want to extend the >>>>> jupyter notebook with new features! >>>>> >>>>> Over the summer, we've been doing small hacks on the ipython notebooks >>>>> from writing tools for cross-notebook imports, joystick (xbox controller) >>>>> widgets, capability for live-tuning control loops, and controlling robots >>>>> and physical devices. >>>>> >>>>> If anybody has ideas and suggestions for jupyter notebook that are >>>>> hurting for implementation, we'd be happy to help. >>>>> >>>>> We'd also love to have company in the Wozniak Lounge from 10am to >>>>> 11pm! (tomorrow, 9/6) >>>>> >>>> >>>> >>>> -- >>>> Kyle Kelley (@rgbkrk ; http://lambdaops.com >>>> ) >>>> >>>> >>> >>> -- >>> Kyle Kelley (@rgbkrk ; http://lambdaops.com) >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: From Stephan.Sahm at gmx.de Tue Sep 9 13:32:49 2014 From: Stephan.Sahm at gmx.de (Stephan Sahm) Date: Tue, 9 Sep 2014 19:32:49 +0200 Subject: [IPython-dev] octavemagic failed Message-ID: Dear all, I use ipython for some years up to now but today it was the first time I tried the octavemagic -- and unfortunately almost everything failed. (copied from my ipython notebook session:) %load_ext octavemagic # works import oct2py o = oct2py.Oct2Py() x = o.eval('[1; 2; 3]') print x # works too, output= [[ 1.] [ 2.] [ 3.]] # but... x = %octave [1 2; 3 4]; # fails ? The ErrorMessage is the following: IndexError Traceback (most recent call last) in ()----> 1 x = get_ipython().magic(u'octave [1 2; 3 4];') /usr/local/lib/python2.7/dist-packages/IPython/core/interactiveshell.pyc in magic(self, arg_s) 2203 magic_name, _, magic_arg_s = arg_s.partition(' ') 2204 magic_name = magic_name.lstrip(prefilter.ESC_MAGIC)-> 2205 return self.run_line_magic(magic_name, magic_arg_s) 2206 2207 #------------------------------------------------------------------------- /usr/local/lib/python2.7/dist-packages/IPython/core/interactiveshell.pyc in run_line_magic(self, magic_name, line) 2124 kwargs['local_ns'] = sys._getframe(stack_depth).f_locals 2125 with self.builtin_trap:-> 2126 result = fn(*args,**kwargs) 2127 return result 2128 /usr/local/lib/python2.7/dist-packages/IPython/extensions/octavemagic.pyc in octave(self, line, cell, local_ns) /usr/local/lib/python2.7/dist-packages/IPython/core/magic.pyc in (f, *a, **k) 191 # but it's overkill for just that one bit of state. 192 def magic_deco(arg):--> 193 call = lambda f, *a, **k: f(*a, **k) 194 195 if callable(arg): /usr/local/lib/python2.7/dist-packages/IPython/extensions/octavemagic.pyc in octave(self, line, cell, local_ns) 327 except (oct2py.Oct2PyError) as exception: 328 msg = exception.message--> 329 msg = msg.split('# ______ #')[1] 330 msg = msg.split('# ______ #')[0] 331 raise OctaveMagicError('Octave could not complete execution. ' IndexError: list index out of range ?? ?? ?using the cell-octave-magic ? %%octave -s 600,200 -f png sombrero() the following related ErrorMessage is thrown: IndexError Traceback (most recent call last) in ()----> 1 get_ipython().run_cell_magic(u'octave', u'-s 600,200 -f png', u'sombrero()') /usr/local/lib/python2.7/dist-packages/IPython/core/interactiveshell.pyc in run_cell_magic(self, magic_name, line, cell) 2160 magic_arg_s = self.var_expand(line, stack_depth) 2161 with self.builtin_trap:-> 2162 result = fn(magic_arg_s, cell) 2163 return result 2164 /usr/local/lib/python2.7/dist-packages/IPython/extensions/octavemagic.pyc in octave(self, line, cell, local_ns) /usr/local/lib/python2.7/dist-packages/IPython/core/magic.pyc in (f, *a, **k) 191 # but it's overkill for just that one bit of state. 192 def magic_deco(arg):--> 193 call = lambda f, *a, **k: f(*a, **k) 194 195 if callable(arg): /usr/local/lib/python2.7/dist-packages/IPython/extensions/octavemagic.pyc in octave(self, line, cell, local_ns) 327 except (oct2py.Oct2PyError) as exception: 328 msg = exception.message--> 329 msg = msg.split('# ______ #')[1] 330 msg = msg.split('# ______ #')[0] 331 raise OctaveMagicError('Octave could not complete execution. ' IndexError: list index out of range ?I have the following version installed oct2py : 2.1? ipython : 2.2 octave : 3.8.1-1ubuntu1 ? I use Ubuntu 14.04 and installed octave via apt-get, oct2py and ipython via pip? Can anyone help me? Of course I would be glad if this is only a small failure and can be fixed soon Hoping for your help, Stephan ?? ?? ?? -------------- next part -------------- An HTML attachment was scrubbed... URL: From takowl at gmail.com Tue Sep 9 13:44:37 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Tue, 9 Sep 2014 10:44:37 -0700 Subject: [IPython-dev] octavemagic failed In-Reply-To: References: Message-ID: Hi Stephan, Octavemagic is now part of Oct2py - try loading the extension as %load_ext oct2py.ipython to get the latest version. If you still see the error, file a bug with oct2py. Thanks, Thomas On 9 September 2014 10:32, Stephan Sahm wrote: > Dear all, > > I use ipython for some years up to now but today it was the first time I > tried the octavemagic -- and unfortunately almost everything failed. > (copied from my ipython notebook session:) > > %load_ext octavemagic # works > > import oct2py > o = oct2py.Oct2Py() > x = o.eval('[1; 2; 3]') > print x > > # works too, output= [[ 1.] > [ 2.] > [ 3.]] > > # but... > > > x = %octave [1 2; 3 4]; # fails > > ? > The ErrorMessage is the following: > > IndexError Traceback (most recent call last) in ()----> 1 x = get_ipython().magic(u'octave [1 2; 3 4];') > /usr/local/lib/python2.7/dist-packages/IPython/core/interactiveshell.pyc in magic(self, arg_s) 2203 magic_name, _, magic_arg_s = arg_s.partition(' ') 2204 magic_name = magic_name.lstrip(prefilter.ESC_MAGIC)-> 2205 return self.run_line_magic(magic_name, magic_arg_s) 2206 2207 #------------------------------------------------------------------------- > /usr/local/lib/python2.7/dist-packages/IPython/core/interactiveshell.pyc in run_line_magic(self, magic_name, line) 2124 kwargs['local_ns'] = sys._getframe(stack_depth).f_locals 2125 with self.builtin_trap:-> 2126 result = fn(*args,**kwargs) 2127 return result 2128 > /usr/local/lib/python2.7/dist-packages/IPython/extensions/octavemagic.pyc in octave(self, line, cell, local_ns) > /usr/local/lib/python2.7/dist-packages/IPython/core/magic.pyc in (f, *a, **k) 191 # but it's overkill for just that one bit of state. 192 def magic_deco(arg):--> 193 call = lambda f, *a, **k: f(*a, **k) 194 195 if callable(arg): > /usr/local/lib/python2.7/dist-packages/IPython/extensions/octavemagic.pyc in octave(self, line, cell, local_ns) 327 except (oct2py.Oct2PyError) as exception: 328 msg = exception.message--> 329 msg = msg.split('# ______ #')[1] 330 msg = msg.split('# ______ #')[0] 331 raise OctaveMagicError('Octave could not complete execution. ' > > > IndexError: list index out of range > > ?? > ?? > ?using the cell-octave-magic ? > > %%octave -s 600,200 -f png > sombrero() > > > the following related ErrorMessage is thrown: > > IndexError Traceback (most recent call last) in ()----> 1 get_ipython().run_cell_magic(u'octave', u'-s 600,200 -f png', u'sombrero()') > /usr/local/lib/python2.7/dist-packages/IPython/core/interactiveshell.pyc in run_cell_magic(self, magic_name, line, cell) 2160 magic_arg_s = self.var_expand(line, stack_depth) 2161 with self.builtin_trap:-> 2162 result = fn(magic_arg_s, cell) 2163 return result 2164 > /usr/local/lib/python2.7/dist-packages/IPython/extensions/octavemagic.pyc in octave(self, line, cell, local_ns) > /usr/local/lib/python2.7/dist-packages/IPython/core/magic.pyc in (f, *a, **k) 191 # but it's overkill for just that one bit of state. 192 def magic_deco(arg):--> 193 call = lambda f, *a, **k: f(*a, **k) 194 195 if callable(arg): > /usr/local/lib/python2.7/dist-packages/IPython/extensions/octavemagic.pyc in octave(self, line, cell, local_ns) 327 except (oct2py.Oct2PyError) as exception: 328 msg = exception.message--> 329 msg = msg.split('# ______ #')[1] 330 msg = msg.split('# ______ #')[0] 331 raise OctaveMagicError('Octave could not complete execution. ' > IndexError: list index out of range > > > > ?I have the following version installed > > oct2py : 2.1? > ipython : 2.2 > octave : 3.8.1-1ubuntu1 > > ? > I use Ubuntu 14.04 and installed octave via apt-get, oct2py and ipython > via pip? > > Can anyone help me? > Of course I would be glad if this is only a small failure and can be fixed > soon > > Hoping for your help, > > Stephan > ?? > ?? > ?? > > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From Stephan.Sahm at gmx.de Tue Sep 9 14:14:21 2014 From: Stephan.Sahm at gmx.de (Stephan Sahm) Date: Tue, 9 Sep 2014 20:14:21 +0200 Subject: [IPython-dev] octavemagic failed In-Reply-To: References: Message-ID: Dear Thomas, thanks a lot for the fast response. The magic does not throw the errors mentioned, instead it simply hangs. I the same behaviour was already registered as a bug however in another setting (see http://stackoverflow.com/questions/24999313/octave-hangs-in-ipython) I browsed some minutes, but could not find a mailinglist or github bug report possibility for octpy. I am not shure how to proceed: Shall I answer on the above stackoverflow? recreating the topic, is something like that possible? Meanwhile I also tried the oct2py version 1.6 (instead of 2.1) specified at the solution from the above link. It is quite slow, but everything works as expected. So it really seems to be a bug in oct2py 2.1 which probably should be forwarded to the right persons. Thanks, Stephan On 9 September 2014 19:44, Thomas Kluyver wrote: > Hi Stephan, > > Octavemagic is now part of Oct2py - try loading the extension as %load_ext > oct2py.ipython to get the latest version. If you still see the error, file > a bug with oct2py. > > Thanks, > Thomas > > On 9 September 2014 10:32, Stephan Sahm wrote: > >> Dear all, >> >> I use ipython for some years up to now but today it was the first time I >> tried the octavemagic -- and unfortunately almost everything failed. >> (copied from my ipython notebook session:) >> >> %load_ext octavemagic # works >> >> import oct2py >> o = oct2py.Oct2Py() >> x = o.eval('[1; 2; 3]') >> print x >> >> # works too, output= [[ 1.] >> [ 2.] >> [ 3.]] >> >> # but... >> >> >> x = %octave [1 2; 3 4]; # fails >> >> ? >> The ErrorMessage is the following: >> >> IndexError Traceback (most recent call last) in ()----> 1 x = get_ipython().magic(u'octave [1 2; 3 4];') >> /usr/local/lib/python2.7/dist-packages/IPython/core/interactiveshell.pyc in magic(self, arg_s) 2203 magic_name, _, magic_arg_s = arg_s.partition(' ') 2204 magic_name = magic_name.lstrip(prefilter.ESC_MAGIC)-> 2205 return self.run_line_magic(magic_name, magic_arg_s) 2206 2207 #------------------------------------------------------------------------- >> /usr/local/lib/python2.7/dist-packages/IPython/core/interactiveshell.pyc in run_line_magic(self, magic_name, line) 2124 kwargs['local_ns'] = sys._getframe(stack_depth).f_locals 2125 with self.builtin_trap:-> 2126 result = fn(*args,**kwargs) 2127 return result 2128 >> /usr/local/lib/python2.7/dist-packages/IPython/extensions/octavemagic.pyc in octave(self, line, cell, local_ns) >> /usr/local/lib/python2.7/dist-packages/IPython/core/magic.pyc in (f, *a, **k) 191 # but it's overkill for just that one bit of state. 192 def magic_deco(arg):--> 193 call = lambda f, *a, **k: f(*a, **k) 194 195 if callable(arg): >> /usr/local/lib/python2.7/dist-packages/IPython/extensions/octavemagic.pyc in octave(self, line, cell, local_ns) 327 except (oct2py.Oct2PyError) as exception: 328 msg = exception.message--> 329 msg = msg.split('# ______ #')[1] 330 msg = msg.split('# ______ #')[0] 331 raise OctaveMagicError('Octave could not complete execution. ' >> >> >> IndexError: list index out of range >> >> ?? >> ?? >> ?using the cell-octave-magic ? >> >> %%octave -s 600,200 -f png >> sombrero() >> >> >> the following related ErrorMessage is thrown: >> >> IndexError Traceback (most recent call last) in ()----> 1 get_ipython().run_cell_magic(u'octave', u'-s 600,200 -f png', u'sombrero()') >> /usr/local/lib/python2.7/dist-packages/IPython/core/interactiveshell.pyc in run_cell_magic(self, magic_name, line, cell) 2160 magic_arg_s = self.var_expand(line, stack_depth) 2161 with self.builtin_trap:-> 2162 result = fn(magic_arg_s, cell) 2163 return result 2164 >> /usr/local/lib/python2.7/dist-packages/IPython/extensions/octavemagic.pyc in octave(self, line, cell, local_ns) >> /usr/local/lib/python2.7/dist-packages/IPython/core/magic.pyc in (f, *a, **k) 191 # but it's overkill for just that one bit of state. 192 def magic_deco(arg):--> 193 call = lambda f, *a, **k: f(*a, **k) 194 195 if callable(arg): >> /usr/local/lib/python2.7/dist-packages/IPython/extensions/octavemagic.pyc in octave(self, line, cell, local_ns) 327 except (oct2py.Oct2PyError) as exception: 328 msg = exception.message--> 329 msg = msg.split('# ______ #')[1] 330 msg = msg.split('# ______ #')[0] 331 raise OctaveMagicError('Octave could not complete execution. ' >> IndexError: list index out of range >> >> >> >> ?I have the following version installed >> >> oct2py : 2.1? >> ipython : 2.2 >> octave : 3.8.1-1ubuntu1 >> >> ? >> I use Ubuntu 14.04 and installed octave via apt-get, oct2py and ipython >> via pip? >> >> Can anyone help me? >> Of course I would be glad if this is only a small failure and can be >> fixed soon >> >> Hoping for your help, >> >> Stephan >> ?? >> ?? >> ?? >> >> >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From doug.blank at gmail.com Tue Sep 9 14:23:55 2014 From: doug.blank at gmail.com (Doug Blank) Date: Tue, 9 Sep 2014 14:23:55 -0400 Subject: [IPython-dev] Parallel support for external wrapperkernels in master? Message-ID: Just wondering if parallel support for external kernels (based on wrapperkernel) is working in master yet, or planned to work soon? Testing: Step 1: start a cluster via dashboard of "calico_scheme_kernel". Step 2: from IPython.parallel import Client client = Client("/home/dblank/.ipython/profile_calico_scheme_kernel/security/ipcontroller-client.json", "profile_calico_scheme_kernel") view = client[:] print view['1/1.0'] which results in answers given by Python, rather than my kernel. Am I doing this correctly? Thanks! -Doug -------------- next part -------------- An HTML attachment was scrubbed... URL: From fperez.net at gmail.com Tue Sep 9 14:24:01 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Tue, 9 Sep 2014 11:24:01 -0700 Subject: [IPython-dev] octavemagic failed In-Reply-To: References: Message-ID: On Tue, Sep 9, 2014 at 11:14 AM, Stephan Sahm wrote: > I browsed some minutes, but could not find a mailinglist or github bug > report possibility for octpy. https://github.com/blink1073/oct2py Cheers f -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: From fperez.net at gmail.com Tue Sep 9 14:25:46 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Tue, 9 Sep 2014 11:25:46 -0700 Subject: [IPython-dev] Parallel support for external wrapperkernels in master? In-Reply-To: References: Message-ID: On Tue, Sep 9, 2014 at 11:23 AM, Doug Blank wrote: > Just wondering if parallel support for external kernels (based on > wrapperkernel) is working in master yet, or planned to work soon? > You always doing the crazy stuff ;) No, we haven't really looked into the intersection of the parallel machinery and alternate kernels. So go forward and blaze trail! :) Cheers, f -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: From raymond.yee at gmail.com Tue Sep 9 14:40:35 2014 From: raymond.yee at gmail.com (Raymond Yee) Date: Tue, 09 Sep 2014 11:40:35 -0700 Subject: [IPython-dev] experience with running IPython parallel with starcluster and/or elasticluster Message-ID: <540F49A3.8050306@gmail.com> Hi everyone, I'm starting to learn how to use IPython parallel and was wondering what the best practices for running a cluster for IPython parallel on Amazon Web Services (AWS). I've started to look into StarCluster (http://star.mit.edu/cluster/) and elasticluster (http://elasticluster.readthedocs.org/en/latest/) because both have IPython support. Anyone have recommendations for one or the other or some alternative? Thanks, -Raymond From fperez.net at gmail.com Tue Sep 9 14:44:36 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Tue, 9 Sep 2014 11:44:36 -0700 Subject: [IPython-dev] experience with running IPython parallel with starcluster and/or elasticluster In-Reply-To: <540F49A3.8050306@gmail.com> References: <540F49A3.8050306@gmail.com> Message-ID: I've only used StarCluster, and happily so. I haven't heard anything about Elasticluster, would love t?o know more if you give it a try (or if others have info on it). Cheers f -------------- next part -------------- An HTML attachment was scrubbed... URL: From doug.blank at gmail.com Tue Sep 9 14:47:43 2014 From: doug.blank at gmail.com (Doug Blank) Date: Tue, 9 Sep 2014 14:47:43 -0400 Subject: [IPython-dev] Parallel support for external wrapperkernels in master? In-Reply-To: References: Message-ID: On Tue, Sep 9, 2014 at 2:25 PM, Fernando Perez wrote: > > On Tue, Sep 9, 2014 at 11:23 AM, Doug Blank wrote: > >> Just wondering if parallel support for external kernels (based on >> wrapperkernel) is working in master yet, or planned to work soon? >> > > You always doing the crazy stuff ;) > > No, we haven't really looked into the intersection of the parallel > machinery and alternate kernels. So go forward and blaze trail! :) > This isn't too crazy, now that y'all have the wrapperkernel nicely factored out :) This must be pretty close to being able to be made to work, at least for those kernels that are Python-based, right? Just can't wait to run the chatbot_kernel in parallel :) -Doug > > Cheers, > > f > -- > Fernando Perez (@fperez_org; http://fperez.org) > fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) > fernando.perez-at-berkeley: contact me here for any direct mail > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From benjaminrk at gmail.com Tue Sep 9 15:05:04 2014 From: benjaminrk at gmail.com (MinRK) Date: Tue, 9 Sep 2014 12:05:04 -0700 Subject: [IPython-dev] Parallel support for external wrapperkernels in master? In-Reply-To: References: Message-ID: There aren't currently plans to make IPython.parallel language agnostic (it will remain an IPython project, not a Jupyter one), because it doesn't make much sense if the Client and Kernel aren't in the same language, so making a kernel available from a new language should also mean writing a new Client object in order for it to be useful. This is distinctly different from the regular kernel-client relationship, which mostly talk code-as-text, which doesn't require the frontend to know much about the kernel. IPython.parallel talks code-as-code (pickle), because it's meant for interacting with actual results, rather than just their representation. -MinRK On Tue, Sep 9, 2014 at 11:47 AM, Doug Blank wrote: > On Tue, Sep 9, 2014 at 2:25 PM, Fernando Perez > wrote: > >> >> On Tue, Sep 9, 2014 at 11:23 AM, Doug Blank wrote: >> >>> Just wondering if parallel support for external kernels (based on >>> wrapperkernel) is working in master yet, or planned to work soon? >>> >> >> You always doing the crazy stuff ;) >> >> No, we haven't really looked into the intersection of the parallel >> machinery and alternate kernels. So go forward and blaze trail! :) >> > > This isn't too crazy, now that y'all have the wrapperkernel nicely > factored out :) > > This must be pretty close to being able to be made to work, at least for > those kernels that are Python-based, right? > > Just can't wait to run the chatbot_kernel in parallel :) > > -Doug > > >> >> Cheers, >> >> f >> -- >> Fernando Perez (@fperez_org; http://fperez.org) >> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) >> fernando.perez-at-berkeley: contact me here for any direct mail >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ra092767 at ime.unicamp.br Tue Sep 9 15:16:20 2014 From: ra092767 at ime.unicamp.br (Raniere Silva) Date: Tue, 9 Sep 2014 16:16:20 -0300 Subject: [IPython-dev] nbconverter exports display latex code instead of math formulas In-Reply-To: References: Message-ID: <20140909191620.GA7725@buriti.rgaiacs.com> Hi David, > Hi I'm beginning to use iPython Notebook on Chrome in a mac os X 10.9. > everything displays normally in the notebook, but when I export it with > nbconvert instead of diplaying the math text written in latex it shows the > latex code. IPython Notebook uses MathJax to properly render LaTeX (it this was good or not is another discussion). When you use nbconvert it will export only the LaTeX formula hoping that you use MathJax (or other solution) to properly render LaTeX. If you are exporting it to HTML should be easy solve this problem. If you are exporting to another format it can be a little more difficult. Hope this helps. Raniere From doug.blank at gmail.com Tue Sep 9 17:05:51 2014 From: doug.blank at gmail.com (Doug Blank) Date: Tue, 9 Sep 2014 17:05:51 -0400 Subject: [IPython-dev] Parallel support for external wrapperkernels in master? In-Reply-To: References: Message-ID: On Tue, Sep 9, 2014 at 3:05 PM, MinRK wrote: > There aren't currently plans to make IPython.parallel language agnostic > (it will remain an IPython project, not a Jupyter one), because it doesn't > make much sense if the Client and Kernel aren't in the same language, so > making a kernel available from a new language should also mean writing a > new Client object in order for it to be useful. This is distinctly > different from the regular kernel-client relationship, which mostly talk > code-as-text, which doesn't require the frontend to know much about the > kernel. IPython.parallel talks code-as-code (pickle), because it's meant > for interacting with actual results, rather than just their representation. > Ok, I understand. Thinking about this a bit, it should be possible to wrap up the Client so that we can start our Python-based kernels on each node in the cluster, and then move values back and forth through some mechanism (maybe just strings, or maybe a serialize/unserialize process). That way, we can still use the IPython infrastructure, and our kernels as well---without having to reinvent too much. Will report back... -Doug > > -MinRK > > On Tue, Sep 9, 2014 at 11:47 AM, Doug Blank wrote: > >> On Tue, Sep 9, 2014 at 2:25 PM, Fernando Perez >> wrote: >> >>> >>> On Tue, Sep 9, 2014 at 11:23 AM, Doug Blank >>> wrote: >>> >>>> Just wondering if parallel support for external kernels (based on >>>> wrapperkernel) is working in master yet, or planned to work soon? >>>> >>> >>> You always doing the crazy stuff ;) >>> >>> No, we haven't really looked into the intersection of the parallel >>> machinery and alternate kernels. So go forward and blaze trail! :) >>> >> >> This isn't too crazy, now that y'all have the wrapperkernel nicely >> factored out :) >> >> This must be pretty close to being able to be made to work, at least for >> those kernels that are Python-based, right? >> >> Just can't wait to run the chatbot_kernel in parallel :) >> >> -Doug >> >> >>> >>> Cheers, >>> >>> f >>> -- >>> Fernando Perez (@fperez_org; http://fperez.org) >>> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) >>> fernando.perez-at-berkeley: contact me here for any direct mail >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From takowl at gmail.com Tue Sep 9 17:44:25 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Tue, 9 Sep 2014 14:44:25 -0700 Subject: [IPython-dev] New feature: Latex escapes tab complete to unicode Message-ID: We've just merged a new feature in master, unashamedly copying something we like from Julia. You can now type Python 3 unicode identifiers in the notebook and the Qt console using Latex-style names. I.e. type \alpha, press tab, and it's replaced by ?. This should work for any character that's valid in identifiers. Thanks to Brian for implementing this in IPython: https://github.com/ipython/ipython/pull/6380 It should be possible to do this in at least the two-process terminal frontend (ipython console) as well, though there's a small bug with it at the moment. Doing it in the single process terminal might be a bit more tricky. Thanks, Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: From ellisonbg at gmail.com Tue Sep 9 17:50:24 2014 From: ellisonbg at gmail.com (Brian Granger) Date: Tue, 9 Sep 2014 14:50:24 -0700 Subject: [IPython-dev] New feature: Latex escapes tab complete to unicode In-Reply-To: References: Message-ID: And thanks to Thomas for helping me get this reviewed and done! Cheers, Brian On Tue, Sep 9, 2014 at 2:44 PM, Thomas Kluyver wrote: > We've just merged a new feature in master, unashamedly copying something we > like from Julia. You can now type Python 3 unicode identifiers in the > notebook and the Qt console using Latex-style names. I.e. type \alpha, press > tab, and it's replaced by ?. This should work for any character that's valid > in identifiers. > > Thanks to Brian for implementing this in IPython: > https://github.com/ipython/ipython/pull/6380 > > It should be possible to do this in at least the two-process terminal > frontend (ipython console) as well, though there's a small bug with it at > the moment. Doing it in the single process terminal might be a bit more > tricky. > > Thanks, > Thomas > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -- Brian E. Granger Cal Poly State University, San Luis Obispo @ellisonbg on Twitter and GitHub bgranger at calpoly.edu and ellisonbg at gmail.com From doug.blank at gmail.com Tue Sep 9 22:41:35 2014 From: doug.blank at gmail.com (Doug Blank) Date: Tue, 9 Sep 2014 22:41:35 -0400 Subject: [IPython-dev] Parallel support for external wrapperkernels in master? In-Reply-To: References: Message-ID: On Tue, Sep 9, 2014 at 5:05 PM, Doug Blank wrote: > On Tue, Sep 9, 2014 at 3:05 PM, MinRK wrote: > >> There aren't currently plans to make IPython.parallel language agnostic >> (it will remain an IPython project, not a Jupyter one), because it doesn't >> make much sense if the Client and Kernel aren't in the same language, so >> making a kernel available from a new language should also mean writing a >> new Client object in order for it to be useful. This is distinctly >> different from the regular kernel-client relationship, which mostly talk >> code-as-text, which doesn't require the frontend to know much about the >> kernel. IPython.parallel talks code-as-code (pickle), because it's meant >> for interacting with actual results, rather than just their representation. >> > > Ok, I understand. Thinking about this a bit, it should be possible to wrap > up the Client so that we can start our Python-based kernels on each node in > the cluster, and then move values back and forth through some mechanism > (maybe just strings, or maybe a serialize/unserialize process). That way, > we can still use the IPython infrastructure, and our kernels as > well---without having to reinvent too much. Will report back... > With just a small bit of code [1], we can start up a wrapperkernel-based kernel on each node of the cluster, and call it directly (without an additional process) to evaluate code. Some of these languages use Python types directly (like our Prolog and Scheme), and so it fits right in with the language with no additional work. Other kernels (like Octave) may take a little more work. In any event, I was able to run Scheme code tonight in parallel, interactively... a longtime goal! With some more refinement, this will be part of a collection of "magics"... metacommands for Python-based 3rd-party kernels. Any of those languages should be able to be run in parallel, at least in a rudimentary fashion. Will announce here soon, as soon as we finish up some loose ends of the project, currently called jupyter_kernel. Thanks again for the hints and feedback, -Doug [1] https://github.com/blink1073/jupyter_kernel/blob/master/jupyter_kernel/magics/parallel_magic.py > -Doug > > >> >> -MinRK >> >> On Tue, Sep 9, 2014 at 11:47 AM, Doug Blank wrote: >> >>> On Tue, Sep 9, 2014 at 2:25 PM, Fernando Perez >>> wrote: >>> >>>> >>>> On Tue, Sep 9, 2014 at 11:23 AM, Doug Blank >>>> wrote: >>>> >>>>> Just wondering if parallel support for external kernels (based on >>>>> wrapperkernel) is working in master yet, or planned to work soon? >>>>> >>>> >>>> You always doing the crazy stuff ;) >>>> >>>> No, we haven't really looked into the intersection of the parallel >>>> machinery and alternate kernels. So go forward and blaze trail! :) >>>> >>> >>> This isn't too crazy, now that y'all have the wrapperkernel nicely >>> factored out :) >>> >>> This must be pretty close to being able to be made to work, at least for >>> those kernels that are Python-based, right? >>> >>> Just can't wait to run the chatbot_kernel in parallel :) >>> >>> -Doug >>> >>> >>>> >>>> Cheers, >>>> >>>> f >>>> -- >>>> Fernando Perez (@fperez_org; http://fperez.org) >>>> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) >>>> fernando.perez-at-berkeley: contact me here for any direct mail >>>> >>>> _______________________________________________ >>>> IPython-dev mailing list >>>> IPython-dev at scipy.org >>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>> >>>> >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From a.kurosawa at gmail.com Wed Sep 10 09:27:27 2014 From: a.kurosawa at gmail.com (David Bernal) Date: Wed, 10 Sep 2014 15:27:27 +0200 Subject: [IPython-dev] nbconverter exports display latex code instead of math formulas In-Reply-To: <20140909191620.GA7725@buriti.rgaiacs.com> References: <20140909191620.GA7725@buriti.rgaiacs.com> Message-ID: Hi Reniere, thanks for answering, although I still have the problem. Let be me more specific, When I try to "print preview" my notebook, or convert it through the terminal with the command "ipython nbconvert mynotebook.ipynb" it changes all the latex formulas to latex code. I put two images so you can see. Recently I realized that before installing anaconda it didn't do that. Also, this appears in the javascript console: Failed to load resource: the server responded with a status of 404 (Not Found) http://localhost:8888/nbconvert/html/custom.css Failed to load resource: the server responded with a status of 404 (Not Found) https://c328740.ssl.cf1.rackcdn.com/mathjax/latest/MathJax.js?config=TeX-AMS_HTML Failed to load resource: the server responded with a status of 404 (Not Found) http://localhost:8888/nbconvert/html/custom.css Any suggestions? Thanks David On Tue, Sep 9, 2014 at 9:16 PM, Raniere Silva wrote: > Hi David, > > > Hi I'm beginning to use iPython Notebook on Chrome in a mac os X 10.9. > > everything displays normally in the notebook, but when I export it with > > nbconvert instead of diplaying the math text written in latex it shows > the > > latex code. > > IPython Notebook uses MathJax to properly render LaTeX (it this was good > or not > is another discussion). When you use nbconvert it will export only the > LaTeX > formula hoping that you use MathJax (or other solution) to properly render > LaTeX. If you are exporting it to HTML should be easy solve this problem. > If you > are exporting to another format it can be a little more difficult. > > Hope this helps. > > Raniere > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: From jiffyclub at gmail.com Wed Sep 10 09:59:32 2014 From: jiffyclub at gmail.com (Matt Davis) Date: Wed, 10 Sep 2014 06:59:32 -0700 Subject: [IPython-dev] nbconverter exports display latex code instead of math formulas In-Reply-To: References: <20140909191620.GA7725@buriti.rgaiacs.com> Message-ID: I don't know if it's related, but in the last couple days I've been unable to load the Mathjax or Reveal libraries via CDN. Seems like something is wrong with it. - Matt On Wednesday, September 10, 2014, David Bernal wrote: > Hi Reniere, > thanks for answering, although I still have the problem. Let be me more > specific, When I try to "print preview" my notebook, or convert it through > the terminal with the command "ipython nbconvert mynotebook.ipynb" it > changes all the latex formulas to latex code. I put two images so you can > see. Recently I realized that before installing anaconda it didn't do that. > Also, this appears in the javascript console: > > Failed to load resource: the server responded with a status of 404 (Not > Found) http://localhost:8888/nbconvert/html/custom.css > > Failed to load resource: the server responded with a status of 404 (Not > Found) > https://c328740.ssl.cf1.rackcdn.com/mathjax/latest/MathJax.js?config=TeX-AMS_HTML > > Failed to load resource: the server responded with a status of 404 (Not > Found) http://localhost:8888/nbconvert/html/custom.css > > Any suggestions? > Thanks > David > > On Tue, Sep 9, 2014 at 9:16 PM, Raniere Silva > wrote: > >> Hi David, >> >> > Hi I'm beginning to use iPython Notebook on Chrome in a mac os X 10.9. >> > everything displays normally in the notebook, but when I export it with >> > nbconvert instead of diplaying the math text written in latex it shows >> the >> > latex code. >> >> IPython Notebook uses MathJax to properly render LaTeX (it this was good >> or not >> is another discussion). When you use nbconvert it will export only the >> LaTeX >> formula hoping that you use MathJax (or other solution) to properly render >> LaTeX. If you are exporting it to HTML should be easy solve this problem. >> If you >> are exporting to another format it can be a little more difficult. >> >> Hope this helps. >> >> Raniere >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From doug.blank at gmail.com Wed Sep 10 10:14:54 2014 From: doug.blank at gmail.com (Doug Blank) Date: Wed, 10 Sep 2014 10:14:54 -0400 Subject: [IPython-dev] Node in cluster know its rank, or cluster size? Message-ID: After reading the docs and tutorial on the parallel tools, and looking at defined variables in the remote environment, I couldn't find a place where a node in a cluster (not using mpi, but just starting the cluster via the notebook with default profile) knows its rank (or some id) and knows the cluster size. Is rank and size information available to a node in the cluster? I guess this could work: view["size"] = len(view) def set_rank(n): global rank rank = n view.execute(""" def set_rank(n): global rank rank = n """) view.map(set_rank, range(len(view))) Better way? My parallel-foo is week. -Doug -------------- next part -------------- An HTML attachment was scrubbed... URL: From bussonniermatthias at gmail.com Wed Sep 10 11:50:05 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Wed, 10 Sep 2014 17:50:05 +0200 Subject: [IPython-dev] nbconverter exports display latex code instead of math formulas In-Reply-To: References: <20140909191620.GA7725@buriti.rgaiacs.com> Message-ID: Le 10 sept. 2014 ? 15:59, Matt Davis a ?crit : > I don't know if it's related, but in the last couple days I've been unable to load the Mathjax or Reveal libraries via CDN. Seems like something is wrong with it. > Mathjax cdn moved. The old address will not work anymore. That the progress of the web. -- M > - Matt > > On Wednesday, September 10, 2014, David Bernal wrote: > Hi Reniere, > thanks for answering, although I still have the problem. Let be me more specific, When I try to "print preview" my notebook, or convert it through the terminal with the command "ipython nbconvert mynotebook.ipynb" it changes all the latex formulas to latex code. I put two images so you can see. Recently I realized that before installing anaconda it didn't do that. > Also, this appears in the javascript console: > > Failed to load resource: the server responded with a status of 404 (Not Found) http://localhost:8888/nbconvert/html/custom.css > > Failed to load resource: the server responded with a status of 404 (Not Found) https://c328740.ssl.cf1.rackcdn.com/mathjax/latest/MathJax.js?config=TeX-AMS_HTML > > Failed to load resource: the server responded with a status of 404 (Not Found) http://localhost:8888/nbconvert/html/custom.css > > Any suggestions? > Thanks > David > > On Tue, Sep 9, 2014 at 9:16 PM, Raniere Silva wrote: > Hi David, > > > Hi I'm beginning to use iPython Notebook on Chrome in a mac os X 10.9. > > everything displays normally in the notebook, but when I export it with > > nbconvert instead of diplaying the math text written in latex it shows the > > latex code. > > IPython Notebook uses MathJax to properly render LaTeX (it this was good or not > is another discussion). When you use nbconvert it will export only the LaTeX > formula hoping that you use MathJax (or other solution) to properly render > LaTeX. If you are exporting it to HTML should be easy solve this problem. If you > are exporting to another format it can be a little more difficult. > > Hope this helps. > > Raniere > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: From rgbkrk at gmail.com Wed Sep 10 13:04:13 2014 From: rgbkrk at gmail.com (Kyle Kelley) Date: Wed, 10 Sep 2014 12:04:13 -0500 Subject: [IPython-dev] nbconverter exports display latex code instead of math formulas In-Reply-To: References: <20140909191620.GA7725@buriti.rgaiacs.com> Message-ID: These are good arguments for vendorizing mathjax. IPython master has the updated URLs as does the notebook viewer. On Wednesday, September 10, 2014, Matthias Bussonnier < bussonniermatthias at gmail.com> wrote: > > Le 10 sept. 2014 ? 15:59, Matt Davis a ?crit : > > I don't know if it's related, but in the last couple days I've been unable > to load the Mathjax or Reveal libraries via CDN. Seems like something is > wrong with it. > > > Mathjax cdn moved. The old address will not work anymore. > > That the progress of the web. > -- > M > > > - Matt > > On Wednesday, September 10, 2014, David Bernal > wrote: > >> Hi Reniere, >> thanks for answering, although I still have the problem. Let be me more >> specific, When I try to "print preview" my notebook, or convert it through >> the terminal with the command "ipython nbconvert mynotebook.ipynb" it >> changes all the latex formulas to latex code. I put two images so you can >> see. Recently I realized that before installing anaconda it didn't do that. >> Also, this appears in the javascript console: >> >> Failed to load resource: the server responded with a status of 404 (Not >> Found) http://localhost:8888/nbconvert/html/custom.css >> >> Failed to load resource: the server responded with a status of 404 (Not >> Found) >> https://c328740.ssl.cf1.rackcdn.com/mathjax/latest/MathJax.js?config=TeX-AMS_HTML >> >> Failed to load resource: the server responded with a status of 404 (Not >> Found) http://localhost:8888/nbconvert/html/custom.css >> >> Any suggestions? >> Thanks >> David >> >> On Tue, Sep 9, 2014 at 9:16 PM, Raniere Silva >> wrote: >> >>> Hi David, >>> >>> > Hi I'm beginning to use iPython Notebook on Chrome in a mac os X 10.9. >>> > everything displays normally in the notebook, but when I export it with >>> > nbconvert instead of diplaying the math text written in latex it shows >>> the >>> > latex code. >>> >>> IPython Notebook uses MathJax to properly render LaTeX (it this was good >>> or not >>> is another discussion). When you use nbconvert it will export only the >>> LaTeX >>> formula hoping that you use MathJax (or other solution) to properly >>> render >>> LaTeX. If you are exporting it to HTML should be easy solve this >>> problem. If you >>> are exporting to another format it can be a little more difficult. >>> >>> Hope this helps. >>> >>> Raniere >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >> >> _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > -- Kyle Kelley (@rgbkrk ; http://lambdaops.com) -------------- next part -------------- An HTML attachment was scrubbed... URL: From benjaminrk at gmail.com Wed Sep 10 13:40:57 2014 From: benjaminrk at gmail.com (MinRK) Date: Wed, 10 Sep 2014 10:40:57 -0700 Subject: [IPython-dev] Node in cluster know its rank, or cluster size? In-Reply-To: References: Message-ID: On Wed, Sep 10, 2014 at 7:14 AM, Doug Blank wrote: After reading the docs and tutorial on the parallel tools, and looking at > defined variables in the remote environment, I couldn't find a place where > a node in a cluster (not using mpi, but just starting the cluster via the > notebook with default profile) knows its rank (or some id) and knows the > cluster size. > > Is rank and size information available to a node in the cluster? > No, you would have to pass this yourself from the client. The code that?s in many of the parallel examples uses scatter: rc[:]['size'] = len(rc) rc[:].scatter('rank', rc.ids, flatten=True) -MinRK > I guess this could work: > > view["size"] = len(view) > > def set_rank(n): > global rank > rank = n > > view.execute(""" > def set_rank(n): > global rank > rank = n > """) > view.map(set_rank, range(len(view))) > > Better way? My parallel-foo is week. > > -Doug > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > ? -------------- next part -------------- An HTML attachment was scrubbed... URL: From doug.blank at gmail.com Wed Sep 10 13:51:48 2014 From: doug.blank at gmail.com (Doug Blank) Date: Wed, 10 Sep 2014 13:51:48 -0400 Subject: [IPython-dev] Node in cluster know its rank, or cluster size? In-Reply-To: References: Message-ID: On Wed, Sep 10, 2014 at 1:40 PM, MinRK wrote: > On Wed, Sep 10, 2014 at 7:14 AM, Doug Blank wrote: > > After reading the docs and tutorial on the parallel tools, and looking at >> defined variables in the remote environment, I couldn't find a place where >> a node in a cluster (not using mpi, but just starting the cluster via the >> notebook with default profile) knows its rank (or some id) and knows the >> cluster size. >> >> Is rank and size information available to a node in the cluster? >> > No, you would have to pass this yourself from the client. The code that?s > in many of the parallel examples uses scatter: > > rc[:]['size'] = len(rc) > rc[:].scatter('rank', rc.ids, flatten=True) > > Thanks! short, sweet, and answers my question! -Doug -MinRK > > >> I guess this could work: >> >> view["size"] = len(view) >> >> def set_rank(n): >> global rank >> rank = n >> >> view.execute(""" >> def set_rank(n): >> global rank >> rank = n >> """) >> view.map(set_rank, range(len(view))) >> >> Better way? My parallel-foo is week. >> >> -Doug >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> ? > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From efiring at hawaii.edu Wed Sep 10 14:00:58 2014 From: efiring at hawaii.edu (Eric Firing) Date: Wed, 10 Sep 2014 08:00:58 -1000 Subject: [IPython-dev] nbconverter exports display latex code instead of math formulas In-Reply-To: References: <20140909191620.GA7725@buriti.rgaiacs.com> Message-ID: <541091DA.8090306@hawaii.edu> On 2014/09/10, 7:04 AM, Kyle Kelley wrote: > These are good arguments for vendorizing mathjax. > > IPython master has the updated URLs as does the notebook viewer. Thanks to Thomas Kluyver, the 2.x branch also has the updated URL now. Eric > > On Wednesday, September 10, 2014, Matthias Bussonnier > > wrote: > > > Le 10 sept. 2014 ? 15:59, Matt Davis a ?crit : > >> I don't know if it's related, but in the last couple days I've >> been unable to load the Mathjax or Reveal libraries via CDN. Seems >> like something is wrong with it. >> > > Mathjax cdn moved. The old address will not work anymore. > > That the progress of the web. > -- > M > > >> - Matt >> >> On Wednesday, September 10, 2014, David Bernal >> > > wrote: >> >> Hi Reniere, >> thanks for answering, although I still have the problem. Let >> be me more specific, When I try to "print preview" my >> notebook, or convert it through the terminal with the command >> "ipython nbconvert mynotebook.ipynb" it changes all the latex >> formulas to latex code. I put two images so you can see. >> Recently I realized that before installing anaconda it didn't >> do that. >> Also, this appears in the javascript console: >> >> Failed to load resource: the server responded with a status of >> 404 (Not Found) http://localhost:8888/nbconvert/html/custom.css >> >> Failed to load resource: the server responded with a status of >> 404 (Not Found) >> https://c328740.ssl.cf1.rackcdn.com/mathjax/latest/MathJax.js?config=TeX-AMS_HTML >> >> Failed to load resource: the server responded with a status of >> 404 (Not Found) http://localhost:8888/nbconvert/html/custom.css >> >> Any suggestions? >> Thanks >> David >> >> On Tue, Sep 9, 2014 at 9:16 PM, Raniere Silva >> wrote: >> >> Hi David, >> >> > Hi I'm beginning to use iPython Notebook on Chrome in a mac os X 10.9. >> > everything displays normally in the notebook, but when I export it with >> > nbconvert instead of diplaying the math text written in latex it shows the >> > latex code. >> >> IPython Notebook uses MathJax to properly render LaTeX (it >> this was good or not >> is another discussion). When you use nbconvert it will >> export only the LaTeX >> formula hoping that you use MathJax (or other solution) to >> properly render >> LaTeX. If you are exporting it to HTML should be easy >> solve this problem. If you >> are exporting to another format it can be a little more >> difficult. >> >> Hope this helps. >> >> Raniere >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> >> http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > -- > Kyle Kelley (@rgbkrk ; http://lambdaops.com > ) > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > From damontallen at gmail.com Wed Sep 10 15:37:18 2014 From: damontallen at gmail.com (Damon Allen) Date: Wed, 10 Sep 2014 15:37:18 -0400 Subject: [IPython-dev] nbconvert Slides: latex and images In-Reply-To: References: <540D8FFF.9030908@gmail.com> Message-ID: Dami?n, I have one more question. I just discovered that HTML tables containing Latex symbols in markdown cells with are not rendering correctly in the slide show. In nbviewer they look fine, and if they are programmaticly generated there are not any problems. The link is an example of the results. http://damontallen.github.io/Construction-Lectures-Fall-2014/Week%2010%20-%20Reshoring.slides.html#/15 vs http://nbviewer.ipython.org/github/damontallen/Construction-Lectures-Fall-2014/blob/master/Week%2010%20-%20Reshoring.ipynb#Filling-out-the-Table Is there a quick modification to fix this too? Thanks, Damon On Mon, Sep 8, 2014 at 10:48 AM, Dami?n Avila wrote: > Damon, yes, it will affect existing slides because all are pointing to the > old CDN... > An easy way to temporarily fix the issue is to use a custom templates with > the correct url... > > Just download this templates in the same folder where your ipynb lives: > > https://gist.github.com/damianavila/ba6a308bd0e605db0e6e > > and run: > > ipython nconvert --to slides --post serve --template slides.tpl > > Hope it helps. > > Damian > > > 2014-09-08 11:28 GMT-03:00 Damon Allen : > > Dami?n, >> >> Should this change in mathjax have affected existing slides online? I've >> just had a student report to me that slides like this one >> >> are not rendering Latex equations. I haven't been running master for >> lecture material development in my class for stability reasons. Is there a >> flag setting that will allow me to use nbconvert with version 2.2 to fix >> this? >> >> Thanks, >> Damon >> >> On Mon, Sep 8, 2014 at 9:09 AM, Dami?n Avila >> wrote: >> >>> Regarding the nbconverted generated slides, if you are using master, >>> some weeks ago mathjax changes the CDN url, so the html and the slides >>> options in nbconvert were affected. Currently on master, the problem is >>> solved... >>> >>> Regarding the images, do you have a minimal example notebook to >>> investigate why is not rendering? >>> >>> And, the documentation is probably outdated, but let me know >>> specifically which part caused you problem. >>> >>> Cheers. >>> >>> 2014-09-08 8:16 GMT-03:00 Andrew Jaffe : >>> >>> Hi all, >>>> >>>> I can set up a slide-show using Fernando Perez's tools from >>>> https://github.com/fperez/nb-slideshow-template >>>> >>>> These work fine, but I like the look (and finer control) of the >>>> nbconvert --to slides --post serve >>>> version. >>>> >>>> However, I don't seem to be able to get mathjax or tags to work >>>> when serving the slides this way. Any ideas? >>>> >>>> Yours, >>>> >>>> Andrew >>>> >>>> p.s. Also, in general, the documentation for all of these things doesn't >>>> seem to be completely synced with the actual production version of >>>> ipython. >>>> _______________________________________________ >>>> IPython-dev mailing list >>>> IPython-dev at scipy.org >>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>> >>> >>> >>> >>> -- >>> *Dami?n* >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > > -- > *Dami?n* > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From damontallen at gmail.com Wed Sep 10 16:57:21 2014 From: damontallen at gmail.com (Damon Allen) Date: Wed, 10 Sep 2014 16:57:21 -0400 Subject: [IPython-dev] nbconvert Slides: latex and images In-Reply-To: References: <540D8FFF.9030908@gmail.com> Message-ID: Never mind. It appears to be a github issue. Sorry about that, Damon Regards, Damon Damon T. Allen Ph.D. Adjunct Professor (352) 234-3266 damontallen at gmail.com 344 Rinker Hall College of Construction Management University of Florida On Mon, Sep 8, 2014 at 10:48 AM, Dami?n Avila wrote: > Damon, yes, it will affect existing slides because all are pointing to the > old CDN... > An easy way to temporarily fix the issue is to use a custom templates with > the correct url... > > Just download this templates in the same folder where your ipynb lives: > > https://gist.github.com/damianavila/ba6a308bd0e605db0e6e > > and run: > > ipython nconvert --to slides --post serve --template slides.tpl > > Hope it helps. > > Damian > > > 2014-09-08 11:28 GMT-03:00 Damon Allen : > > Dami?n, >> >> Should this change in mathjax have affected existing slides online? I've >> just had a student report to me that slides like this one >> >> are not rendering Latex equations. I haven't been running master for >> lecture material development in my class for stability reasons. Is there a >> flag setting that will allow me to use nbconvert with version 2.2 to fix >> this? >> >> Thanks, >> Damon >> >> On Mon, Sep 8, 2014 at 9:09 AM, Dami?n Avila >> wrote: >> >>> Regarding the nbconverted generated slides, if you are using master, >>> some weeks ago mathjax changes the CDN url, so the html and the slides >>> options in nbconvert were affected. Currently on master, the problem is >>> solved... >>> >>> Regarding the images, do you have a minimal example notebook to >>> investigate why is not rendering? >>> >>> And, the documentation is probably outdated, but let me know >>> specifically which part caused you problem. >>> >>> Cheers. >>> >>> 2014-09-08 8:16 GMT-03:00 Andrew Jaffe : >>> >>> Hi all, >>>> >>>> I can set up a slide-show using Fernando Perez's tools from >>>> https://github.com/fperez/nb-slideshow-template >>>> >>>> These work fine, but I like the look (and finer control) of the >>>> nbconvert --to slides --post serve >>>> version. >>>> >>>> However, I don't seem to be able to get mathjax or tags to work >>>> when serving the slides this way. Any ideas? >>>> >>>> Yours, >>>> >>>> Andrew >>>> >>>> p.s. Also, in general, the documentation for all of these things doesn't >>>> seem to be completely synced with the actual production version of >>>> ipython. >>>> _______________________________________________ >>>> IPython-dev mailing list >>>> IPython-dev at scipy.org >>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>> >>> >>> >>> >>> -- >>> *Dami?n* >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > > -- > *Dami?n* > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From fperez.net at gmail.com Wed Sep 10 17:38:50 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Wed, 10 Sep 2014 14:38:50 -0700 Subject: [IPython-dev] Node in cluster know its rank, or cluster size? In-Reply-To: References: Message-ID: Doug, On Wed, Sep 10, 2014 at 10:51 AM, Doug Blank wrote: > Thanks! short, sweet, and answers my question! > You may also want to have a quick look at the first cells in this notebook: http://nbviewer.ipython.org/github/ipython/ipython/blob/2.x/examples/Parallel%20Computing/Monitoring%20an%20MPI%20Simulation%20-%201.ipynb that show you how to write a little utility (mpi_order) that can be used to get a sequence in MPI-rank order after you've gathered it from your IPython nodes. Very useful for domain decomposition problems where you want to reconstruct in the client a data strucutre that's spatially distributed over the MPI nodes. See how it's used further down in that same notebook. Cheers, f -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: From fperez.net at gmail.com Wed Sep 10 17:39:58 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Wed, 10 Sep 2014 14:39:58 -0700 Subject: [IPython-dev] Parallel support for external wrapperkernels in master? In-Reply-To: References: Message-ID: On Tue, Sep 9, 2014 at 7:41 PM, Doug Blank wrote: > With some more refinement, this will be part of a collection of > "magics"... metacommands for Python-based 3rd-party kernels. Any of those > languages should be able to be run in parallel, at least in a rudimentary > fashion. Will announce here soon, as soon as we finish up some loose ends > of the project, currently called jupyter_kernel. > > Thanks again for the hints and feedback, > Wonderful, thanks for letting us know... If we were a bit more willing to play that game, there's quite a few cool papers on interactive parallel computing that we've been meaning to write. This would add to that collection :) Cheers f -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: From doug.blank at gmail.com Wed Sep 10 17:48:21 2014 From: doug.blank at gmail.com (Doug Blank) Date: Wed, 10 Sep 2014 17:48:21 -0400 Subject: [IPython-dev] Node in cluster know its rank, or cluster size? In-Reply-To: References: Message-ID: On Wed, Sep 10, 2014 at 5:38 PM, Fernando Perez wrote: > Doug, > > On Wed, Sep 10, 2014 at 10:51 AM, Doug Blank wrote: > >> Thanks! short, sweet, and answers my question! >> > > You may also want to have a quick look at the first cells in this notebook: > > > http://nbviewer.ipython.org/github/ipython/ipython/blob/2.x/examples/Parallel%20Computing/Monitoring%20an%20MPI%20Simulation%20-%201.ipynb > > that show you how to write a little utility (mpi_order) that can be used > to get a sequence in MPI-rank order after you've gathered it from your > IPython nodes. Very useful for domain decomposition problems where you want > to reconstruct in the client a data strucutre that's spatially distributed > over the MPI nodes. See how it's used further down in that same notebook. > Thanks, Fernando... that's exactly the type of algorithm I was thinking of, I just couldn't find such values since I wasn't using MPI. But Min's little snip-it has me up and running. This is truly a lovely environment... switching languages, graphics, plotting, data, and just now discovering the parallel tools. -Doug > > Cheers, > > f > > -- > Fernando Perez (@fperez_org; http://fperez.org) > fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) > fernando.perez-at-berkeley: contact me here for any direct mail > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From Sebastien.Hinderer at inria.fr Thu Sep 11 08:31:58 2014 From: Sebastien.Hinderer at inria.fr (=?utf-8?Q?S=C3=A9bastien?= Hinderer) Date: Thu, 11 Sep 2014 14:31:58 +0200 Subject: [IPython-dev] Shared profile , distinct security dirs Message-ID: <20140911123158.GA29249@pl-59055.rocqadm.inria.fr> Dear all, I'm running ipython notebook with the --profile-dir= option. I'd like to make it possible for all users to share the same system-wide profile directory while having each their distinct security directory. So far I was not able to achieve this. ipython tries to create the security directory inside the profile directory and gets a permission denied, which is normal. I tried specifying the --ipython-dir option in addition, but that does not seem to have an impact. Is there a way to achieve this, please? Thanks! S?bastien. From bussonniermatthias at gmail.com Thu Sep 11 11:59:18 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Thu, 11 Sep 2014 17:59:18 +0200 Subject: [IPython-dev] Shared profile , distinct security dirs In-Reply-To: <20140911123158.GA29249@pl-59055.rocqadm.inria.fr> References: <20140911123158.GA29249@pl-59055.rocqadm.inria.fr> Message-ID: <2551E5E6-20B8-42C4-A8E5-3E4C0A77C793@gmail.com> Le 11 sept. 2014 ? 14:31, S?bastien Hinderer a ?crit : > Dear all, > > I'm running ipython notebook with the --profile-dir= option. > I'd like to make it possible for all users to share the same system-wide > profile directory while having each their distinct security directory. Probably not. > So far I was not able to achieve this. ipython tries to create the > security directory inside the profile directory and gets a permission > denied, which is normal. I tried specifying the --ipython-dir option in > addition, but that does not seem to have an impact. > > Is there a way to achieve this, please? create the profile dir yourself and symlink everything to the shared one, except security ? -- M > > Thanks! > S?bastien. > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From Sebastien.Hinderer at inria.fr Thu Sep 11 12:03:03 2014 From: Sebastien.Hinderer at inria.fr (=?utf-8?Q?S=C3=A9bastien?= Hinderer) Date: Thu, 11 Sep 2014 18:03:03 +0200 Subject: [IPython-dev] Shared profile , distinct security dirs In-Reply-To: <2551E5E6-20B8-42C4-A8E5-3E4C0A77C793@gmail.com> References: <20140911123158.GA29249@pl-59055.rocqadm.inria.fr> <2551E5E6-20B8-42C4-A8E5-3E4C0A77C793@gmail.com> Message-ID: <20140911160303.GA31239@pl-59055.rocqadm.inria.fr> Hi Matthias, many thanks for your prompt response! Matthias Bussonnier (2014/09/11 17:59 +0200): > create the profile dir yourself and symlink everything to the shared > one, except security ? Yes, looks as an acceptable compromise, thanks! S?bastien. From takowl at gmail.com Thu Sep 11 15:23:58 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Thu, 11 Sep 2014 12:23:58 -0700 Subject: [IPython-dev] PR squashing meeting Message-ID: We said in our dev meeting that we should schedule a time to go through PRs, especially those labelled 'needs decision', and work out what we want to do. In keeping with our general pattern, does next Tuesday at 1700 UTC (10am in California, 7pm in France) work for enough people? We don't need everyone to be there. Thanks, Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: From Stephan.Sahm at gmx.de Thu Sep 11 15:46:33 2014 From: Stephan.Sahm at gmx.de (Stephan Sahm) Date: Thu, 11 Sep 2014 21:46:33 +0200 Subject: [IPython-dev] several bugs in ipython nbconvert --to latex Message-ID: Dear all, today "ipython nbconvert --to pdf" didn't worked on my ipython notebook. I spend some hours to break the errors down and surprisingly found a whole bunch of bugs in the conversion from the notebook to the latex representation (at least compared to the html version). I made a little notebook with the example cases and descriptions how far I understood the bugs. It would be great if someone who knows how to fix those can do so for the next release. I used the current git-version from ipython (11.09.2014, branch master) on Ubuntu 14.04. (I used texlive-full as latex) As I now understand how to circumvent the gaps, I can use the latex conversion perfectly, but nevertheless I think those bugs deserve to be fixed. One feature request to the end: if the latex conversion works right, it would be great to have a kind of "export as..." menu-entry in a future ipython notebook to select several formats like especially latex and pdf(through latex). hoping for some reply, with best wishes, Stephan -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: latex_bug_report.tar.gz Type: application/x-gzip Size: 317890 bytes Desc: not available URL: From damianavila at gmail.com Thu Sep 11 16:02:22 2014 From: damianavila at gmail.com (=?UTF-8?Q?Dami=C3=A1n_Avila?=) Date: Thu, 11 Sep 2014 17:02:22 -0300 Subject: [IPython-dev] PR squashing meeting In-Reply-To: References: Message-ID: It works for me... 2014-09-11 16:23 GMT-03:00 Thomas Kluyver : > We said in our dev meeting that we should schedule a time to go through > PRs, especially those labelled 'needs decision', and work out what we want > to do. > > In keeping with our general pattern, does next Tuesday at 1700 UTC (10am > in California, 7pm in France) work for enough people? We don't need > everyone to be there. > > Thanks, > Thomas > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- *Dami?n* -------------- next part -------------- An HTML attachment was scrubbed... URL: From ellisonbg at gmail.com Thu Sep 11 17:08:31 2014 From: ellisonbg at gmail.com (Brian Granger) Date: Thu, 11 Sep 2014 14:08:31 -0700 Subject: [IPython-dev] PR squashing meeting In-Reply-To: References: Message-ID: Fernando and I had talked about keeping these meetings short - 2 or 3 decisions/PRs at most. With 10 current decisions to make I don't think we should wait for Tuesday - by then we may have 15 ;-) Tomorrow at 10 am for the first 2-3? Sent from my iPhone > On Sep 11, 2014, at 1:02 PM, Dami?n Avila wrote: > > It works for me... > > 2014-09-11 16:23 GMT-03:00 Thomas Kluyver : >> We said in our dev meeting that we should schedule a time to go through PRs, especially those labelled 'needs decision', and work out what we want to do. >> >> In keeping with our general pattern, does next Tuesday at 1700 UTC (10am in California, 7pm in France) work for enough people? We don't need everyone to be there. >> >> Thanks, >> Thomas >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > -- > Dami?n > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: From ellisonbg at gmail.com Thu Sep 11 17:09:34 2014 From: ellisonbg at gmail.com (Brian Granger) Date: Thu, 11 Sep 2014 14:09:34 -0700 Subject: [IPython-dev] several bugs in ipython nbconvert --to latex In-Reply-To: References: Message-ID: <6DA11D77-5DE3-4CB0-AE9B-12B86101DB8A@gmail.com> Thanks I had noticed these problems as well Sent from my iPhone > On Sep 11, 2014, at 12:46 PM, Stephan Sahm wrote: > > Dear all, > > today "ipython nbconvert --to pdf" didn't worked on my ipython notebook. I spend some hours to break the errors down and surprisingly found a whole bunch of bugs in the conversion from the notebook to the latex representation (at least compared to the html version). > > I made a little notebook with the example cases and descriptions how far I understood the bugs. > It would be great if someone who knows how to fix those can do so for the next release. > > I used the current git-version from ipython (11.09.2014, branch master) on Ubuntu 14.04. (I used texlive-full as latex) > > As I now understand how to circumvent the gaps, I can use the latex conversion perfectly, but nevertheless I think those bugs deserve to be fixed. > > One feature request to the end: if the latex conversion works right, it would be great to have a kind of "export as..." menu-entry in a future ipython notebook to select several formats like especially latex and pdf(through latex). > > hoping for some reply, > > with best wishes, > > Stephan > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: From takowl at gmail.com Thu Sep 11 17:32:29 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Thu, 11 Sep 2014 14:32:29 -0700 Subject: [IPython-dev] PR squashing meeting In-Reply-To: References: Message-ID: OK, let's go for tomorrow at the same time. In fact, shall we say that, if there are 3 or more PRs labeled needs decision, whoever's around at 10am on any working day should get together and try to either decide, or work out whose input is needed? Thomas On 11 September 2014 14:08, Brian Granger wrote: > Fernando and I had talked about keeping these meetings short - 2 or 3 > decisions/PRs at most. > > With 10 current decisions to make I don't think we should wait for Tuesday > - by then we may have 15 ;-) > > Tomorrow at 10 am for the first 2-3? > > Sent from my iPhone > > On Sep 11, 2014, at 1:02 PM, Dami?n Avila wrote: > > It works for me... > > 2014-09-11 16:23 GMT-03:00 Thomas Kluyver : > >> We said in our dev meeting that we should schedule a time to go through >> PRs, especially those labelled 'needs decision', and work out what we want >> to do. >> >> In keeping with our general pattern, does next Tuesday at 1700 UTC (10am >> in California, 7pm in France) work for enough people? We don't need >> everyone to be there. >> >> Thanks, >> Thomas >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > > -- > *Dami?n* > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From damianavila at gmail.com Thu Sep 11 17:37:07 2014 From: damianavila at gmail.com (=?UTF-8?Q?Dami=C3=A1n_Avila?=) Date: Thu, 11 Sep 2014 18:37:07 -0300 Subject: [IPython-dev] PR squashing meeting In-Reply-To: References: Message-ID: > In fact, shall we say that, if there are 3 or more PRs labeled needs decision, whoever's around at 10am on any working day should get together and try to either decide, or work out whose input is needed? Sounds good... 2014-09-11 18:32 GMT-03:00 Thomas Kluyver : > OK, let's go for tomorrow at the same time. > > In fact, shall we say that, if there are 3 or more PRs labeled needs > decision, whoever's around at 10am on any working day should get together > and try to either decide, or work out whose input is needed? > > Thomas > > On 11 September 2014 14:08, Brian Granger wrote: > >> Fernando and I had talked about keeping these meetings short - 2 or 3 >> decisions/PRs at most. >> >> With 10 current decisions to make I don't think we should wait for >> Tuesday - by then we may have 15 ;-) >> >> Tomorrow at 10 am for the first 2-3? >> >> Sent from my iPhone >> >> On Sep 11, 2014, at 1:02 PM, Dami?n Avila wrote: >> >> It works for me... >> >> 2014-09-11 16:23 GMT-03:00 Thomas Kluyver : >> >>> We said in our dev meeting that we should schedule a time to go through >>> PRs, especially those labelled 'needs decision', and work out what we want >>> to do. >>> >>> In keeping with our general pattern, does next Tuesday at 1700 UTC (10am >>> in California, 7pm in France) work for enough people? We don't need >>> everyone to be there. >>> >>> Thanks, >>> Thomas >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> >> >> -- >> *Dami?n* >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- *Dami?n* -------------- next part -------------- An HTML attachment was scrubbed... URL: From ellisonbg at gmail.com Thu Sep 11 17:48:42 2014 From: ellisonbg at gmail.com (Brian Granger) Date: Thu, 11 Sep 2014 14:48:42 -0700 Subject: [IPython-dev] PR squashing meeting In-Reply-To: References: Message-ID: On Thu, Sep 11, 2014 at 2:37 PM, Dami?n Avila wrote: >> In fact, shall we say that, if there are 3 or more PRs labeled needs >> decision, whoever's around at 10am on any working day should get together >> and try to either decide, or work out whose input is needed? I very much like that idea - I think it will help ease some of the bottlenecks we have - esp if we can keep the meetings short. Maybe we should even time limit them to 30 minutes? Cheers, Brian > Sounds good... > > 2014-09-11 18:32 GMT-03:00 Thomas Kluyver : > >> OK, let's go for tomorrow at the same time. >> >> In fact, shall we say that, if there are 3 or more PRs labeled needs >> decision, whoever's around at 10am on any working day should get together >> and try to either decide, or work out whose input is needed? >> >> Thomas >> >> On 11 September 2014 14:08, Brian Granger wrote: >>> >>> Fernando and I had talked about keeping these meetings short - 2 or 3 >>> decisions/PRs at most. >>> >>> With 10 current decisions to make I don't think we should wait for >>> Tuesday - by then we may have 15 ;-) >>> >>> Tomorrow at 10 am for the first 2-3? >>> >>> Sent from my iPhone >>> >>> On Sep 11, 2014, at 1:02 PM, Dami?n Avila wrote: >>> >>> It works for me... >>> >>> 2014-09-11 16:23 GMT-03:00 Thomas Kluyver : >>>> >>>> We said in our dev meeting that we should schedule a time to go through >>>> PRs, especially those labelled 'needs decision', and work out what we want >>>> to do. >>>> >>>> In keeping with our general pattern, does next Tuesday at 1700 UTC (10am >>>> in California, 7pm in France) work for enough people? We don't need everyone >>>> to be there. >>>> >>>> Thanks, >>>> Thomas >>>> >>>> _______________________________________________ >>>> IPython-dev mailing list >>>> IPython-dev at scipy.org >>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>> >>> >>> >>> >>> -- >>> Dami?n >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> > > > > -- > Dami?n > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -- Brian E. Granger Cal Poly State University, San Luis Obispo @ellisonbg on Twitter and GitHub bgranger at calpoly.edu and ellisonbg at gmail.com From takowl at gmail.com Thu Sep 11 18:07:32 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Thu, 11 Sep 2014 15:07:32 -0700 Subject: [IPython-dev] PR squashing meeting In-Reply-To: References: Message-ID: Let's see how we go with the first one. On 11 September 2014 14:48, Brian Granger wrote: > On Thu, Sep 11, 2014 at 2:37 PM, Dami?n Avila > wrote: > >> In fact, shall we say that, if there are 3 or more PRs labeled needs > >> decision, whoever's around at 10am on any working day should get > together > >> and try to either decide, or work out whose input is needed? > > I very much like that idea - I think it will help ease some of the > bottlenecks we have - esp if we can keep the meetings short. Maybe we > should even time limit them to 30 minutes? > > Cheers, > > Brian > > > Sounds good... > > > > 2014-09-11 18:32 GMT-03:00 Thomas Kluyver : > > > >> OK, let's go for tomorrow at the same time. > >> > >> In fact, shall we say that, if there are 3 or more PRs labeled needs > >> decision, whoever's around at 10am on any working day should get > together > >> and try to either decide, or work out whose input is needed? > >> > >> Thomas > >> > >> On 11 September 2014 14:08, Brian Granger wrote: > >>> > >>> Fernando and I had talked about keeping these meetings short - 2 or 3 > >>> decisions/PRs at most. > >>> > >>> With 10 current decisions to make I don't think we should wait for > >>> Tuesday - by then we may have 15 ;-) > >>> > >>> Tomorrow at 10 am for the first 2-3? > >>> > >>> Sent from my iPhone > >>> > >>> On Sep 11, 2014, at 1:02 PM, Dami?n Avila > wrote: > >>> > >>> It works for me... > >>> > >>> 2014-09-11 16:23 GMT-03:00 Thomas Kluyver : > >>>> > >>>> We said in our dev meeting that we should schedule a time to go > through > >>>> PRs, especially those labelled 'needs decision', and work out what we > want > >>>> to do. > >>>> > >>>> In keeping with our general pattern, does next Tuesday at 1700 UTC > (10am > >>>> in California, 7pm in France) work for enough people? We don't need > everyone > >>>> to be there. > >>>> > >>>> Thanks, > >>>> Thomas > >>>> > >>>> _______________________________________________ > >>>> IPython-dev mailing list > >>>> IPython-dev at scipy.org > >>>> http://mail.scipy.org/mailman/listinfo/ipython-dev > >>>> > >>> > >>> > >>> > >>> -- > >>> Dami?n > >>> > >>> _______________________________________________ > >>> IPython-dev mailing list > >>> IPython-dev at scipy.org > >>> http://mail.scipy.org/mailman/listinfo/ipython-dev > >>> > >>> > >>> _______________________________________________ > >>> IPython-dev mailing list > >>> IPython-dev at scipy.org > >>> http://mail.scipy.org/mailman/listinfo/ipython-dev > >>> > >> > >> > >> _______________________________________________ > >> IPython-dev mailing list > >> IPython-dev at scipy.org > >> http://mail.scipy.org/mailman/listinfo/ipython-dev > >> > > > > > > > > -- > > Dami?n > > > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > > > -- > Brian E. Granger > Cal Poly State University, San Luis Obispo > @ellisonbg on Twitter and GitHub > bgranger at calpoly.edu and ellisonbg at gmail.com > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bussonniermatthias at gmail.com Fri Sep 12 05:26:25 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Fri, 12 Sep 2014 11:26:25 +0200 Subject: [IPython-dev] PR squashing meeting In-Reply-To: References: Message-ID: <85B5EC19-28E5-4E31-9520-B96D99B842C0@gmail.com> No for me until next week, but please go forward. I suppose some of the decisions could also be speed up with each core dev commenting on the sides wether or not (maybe why) we are against or for the feature. -- M Envoy? de mon iPhone > Le 11 sept. 2014 ? 21:23, Thomas Kluyver a ?crit : > > We said in our dev meeting that we should schedule a time to go through PRs, especially those labelled 'needs decision', and work out what we want to do. > > In keeping with our general pattern, does next Tuesday at 1700 UTC (10am in California, 7pm in France) work for enough people? We don't need everyone to be there. > > Thanks, > Thomas > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From fperez.net at gmail.com Fri Sep 12 14:39:05 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Fri, 12 Sep 2014 11:39:05 -0700 Subject: [IPython-dev] several bugs in ipython nbconvert --to latex In-Reply-To: <6DA11D77-5DE3-4CB0-AE9B-12B86101DB8A@gmail.com> References: <6DA11D77-5DE3-4CB0-AE9B-12B86101DB8A@gmail.com> Message-ID: Quick q: is this captured in a bug report somewhere? Otherwise we'll lose track of it... On Thu, Sep 11, 2014 at 2:09 PM, Brian Granger wrote: > Thanks I had noticed these problems as well > > Sent from my iPhone > > On Sep 11, 2014, at 12:46 PM, Stephan Sahm wrote: > > Dear all, > > today "ipython nbconvert --to pdf" didn't worked on my ipython notebook. I > spend some hours to break the errors down and surprisingly found a whole > bunch of bugs in the conversion from the notebook to the latex > representation (at least compared to the html version). > > I made a little notebook with the example cases and descriptions how far I > understood the bugs. > It would be great if someone who knows how to fix those can do so for the > next release. > > I used the current git-version from ipython (11.09.2014, branch master) on > Ubuntu 14.04. (I used texlive-full as latex) > > As I now understand how to circumvent the gaps, I can use the latex > conversion perfectly, but nevertheless I think those bugs deserve to be > fixed. > > One feature request to the end: if the latex conversion works right, it > would be great to have a kind of "export as..." menu-entry in a future > ipython notebook to select several formats like especially latex and > pdf(through latex). > > hoping for some reply, > > with best wishes, > > Stephan > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: From doug.blank at gmail.com Fri Sep 12 17:17:06 2014 From: doug.blank at gmail.com (Doug Blank) Date: Fri, 12 Sep 2014 17:17:06 -0400 Subject: [IPython-dev] Environment in load balanced map_async? Message-ID: Can you imagine why this would fail: view_load_balanced.map_async( lambda arg: kernels.do_function_direct(arg), [1, 2, 3]) but that this ugly, terrible hack would work: view.execute(""" import os os.kernels = kernels """) view_load_balanced.map_async( lambda arg: os.kernels.do_function_direct(arg), [1, 2, 3]) Why would I not be able to find a variable in the environment, but I can put it in a module, and find it there? -Doug -------------- next part -------------- An HTML attachment was scrubbed... URL: From benjaminrk at gmail.com Fri Sep 12 19:21:20 2014 From: benjaminrk at gmail.com (MinRK) Date: Fri, 12 Sep 2014 16:21:20 -0700 Subject: [IPython-dev] Environment in load balanced map_async? In-Reply-To: References: Message-ID: This is the single most common confusion users face when getting started with IPython.parallel: namespace management, which I have discussed on Stack Overflow a few times , and in the IPython.parallel tutorial . The gist is that in your code, kernels is just a reference to __main__.kernels on the engine, which hasn?t been defined. You would solve the same problem with view['kernels'] = kernels, or (depending on what `kernels` is, this doesn?t always work for serialization reasons) view.map_async(kernels.do_function_direct, [1,2,3]). -MinRK ? On Fri, Sep 12, 2014 at 2:17 PM, Doug Blank wrote: > Can you imagine why this would fail: > > view_load_balanced.map_async( > lambda arg: kernels.do_function_direct(arg), > [1, 2, 3]) > > but that this ugly, terrible hack would work: > > view.execute(""" > import os > os.kernels = kernels > """) > view_load_balanced.map_async( > lambda arg: os.kernels.do_function_direct(arg), > [1, 2, 3]) > > Why would I not be able to find a variable in the environment, but I can > put it in a module, and find it there? > > -Doug > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From doug.blank at gmail.com Fri Sep 12 19:49:05 2014 From: doug.blank at gmail.com (Doug Blank) Date: Fri, 12 Sep 2014 19:49:05 -0400 Subject: [IPython-dev] Environment in load balanced map_async? In-Reply-To: References: Message-ID: On Fri, Sep 12, 2014 at 7:21 PM, MinRK wrote: > This is the single most common confusion users face when getting started > with IPython.parallel: namespace management, which I have discussed on > Stack Overflow a few > > times , and in the IPython.parallel > tutorial > > . > > The gist is that in your code, kernels is just a reference to > __main__.kernels on the engine, which hasn?t been defined. You would > solve the same problem with view['kernels'] = kernels, or (depending on > what `kernels` is, this doesn?t always work for serialization reasons) view.map_async(kernels.do_function_direct, > [1,2,3]). > Thanks for these many answers :) kernels couldn't be serialized, and neither could the method do_function_direct. The interactive function wrapper solved the problem. -Doug > -MinRK > ? > > On Fri, Sep 12, 2014 at 2:17 PM, Doug Blank wrote: > >> Can you imagine why this would fail: >> >> view_load_balanced.map_async( >> lambda arg: kernels.do_function_direct(arg), >> [1, 2, 3]) >> >> but that this ugly, terrible hack would work: >> >> view.execute(""" >> import os >> os.kernels = kernels >> """) >> view_load_balanced.map_async( >> lambda arg: os.kernels.do_function_direct(arg), >> [1, 2, 3]) >> >> Why would I not be able to find a variable in the environment, but I can >> put it in a module, and find it there? >> >> -Doug >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From arne.wolframm at gmail.com Sat Sep 13 10:53:04 2014 From: arne.wolframm at gmail.com (Arne Wolframm) Date: Sat, 13 Sep 2014 16:53:04 +0200 Subject: [IPython-dev] ZMQ and Tornardo Message-ID: Hi, I am currently trying to understand Ipython's architecture. Could someone explain where Ipyhton uses ZMQ and where it uses Tornado? Regards, Arne -------------- next part -------------- An HTML attachment was scrubbed... URL: From grantwp3 at gmail.com Sat Sep 13 14:02:00 2014 From: grantwp3 at gmail.com (gpetty) Date: Sat, 13 Sep 2014 11:02:00 -0700 (PDT) Subject: [IPython-dev] Best approach for uploading files through the Notebook? In-Reply-To: References: Message-ID: <1410631320692-5071529.post@n6.nabble.com> Any progress on this issue? I was excited to discover NBCloud and would like to use it in the classroom, but the inability to easily upload/download data files to the remote server could be a show-stopper. Thanks, Grant -- View this message in context: http://python.6.x6.nabble.com/Best-approach-for-uploading-files-through-the-Notebook-tp4979718p5071529.html Sent from the IPython - Development mailing list archive at Nabble.com. From benjaminrk at gmail.com Sat Sep 13 15:26:21 2014 From: benjaminrk at gmail.com (MinRK) Date: Sat, 13 Sep 2014 12:26:21 -0700 Subject: [IPython-dev] ZMQ and Tornardo In-Reply-To: References: Message-ID: IPython uses zmq when Python processes talk to each other (kernel->Python frontend, such as qtconsole, zmq console, notebook server) and tornado when talking to browsers (notebook-server->browser). -MinRK On Sat, Sep 13, 2014 at 7:53 AM, Arne Wolframm wrote: > Hi, > > I am currently trying to understand Ipython's architecture. > > Could someone explain where Ipyhton uses ZMQ and where it uses Tornado? > > Regards, > > Arne > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From nolan.nichols at gmail.com Sat Sep 13 17:32:06 2014 From: nolan.nichols at gmail.com (Nolan Nichols) Date: Sat, 13 Sep 2014 14:32:06 -0700 Subject: [IPython-dev] API to Modify Notebook Metadata Message-ID: Hi, I'm curious if it is yet possible to edit the Notebook Metadata programatically. I'm familiar with how to do this in the UI manually, but would like to simply inject some json into the metadata using code. Thanks! Cheers, Nolan -------------- next part -------------- An HTML attachment was scrubbed... URL: From benjaminrk at gmail.com Sat Sep 13 17:55:58 2014 From: benjaminrk at gmail.com (MinRK) Date: Sat, 13 Sep 2014 14:55:58 -0700 Subject: [IPython-dev] API to Modify Notebook Metadata In-Reply-To: References: Message-ID: It?s relatively straightforward to do this from Javascript: IPython.notebook.metadata.key = "value"; There isn?t an API to use from Python, other than raw execution of the above javascript: from IPython.display import display_javascript display_javascript('IPython.notebook.metadata.key = "value";', raw=True) -MinRK ? On Sat, Sep 13, 2014 at 2:32 PM, Nolan Nichols wrote: > Hi, > > I'm curious if it is yet possible to edit the Notebook Metadata > programatically. I'm familiar with how to do this in the UI manually, but > would like to simply inject some json into the metadata using code. Thanks! > > Cheers, > > Nolan > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From wes.turner at gmail.com Sat Sep 13 21:42:12 2014 From: wes.turner at gmail.com (Wes Turner) Date: Sat, 13 Sep 2014 20:42:12 -0500 Subject: [IPython-dev] API to Modify Notebook Metadata In-Reply-To: References: Message-ID: Could this functionality be used for storing JSON-LD metadata which maps to dcterms and/or schema.org? * Python: pyld, rdflib-jsonld * Javscript: http://www.w3.org/community/rdfjs/wiki/Comparison_of_RDFJS_libraries ... It would be great to be able to index notebooks by datasets referenced. -- Wes Turner On Sat, Sep 13, 2014 at 4:55 PM, MinRK wrote: > It?s relatively straightforward to do this from Javascript: > > IPython.notebook.metadata.key = "value"; > > There isn?t an API to use from Python, other than raw execution of the above > javascript: > > from IPython.display import display_javascript > display_javascript('IPython.notebook.metadata.key = "value";', raw=True) > > -MinRK > > > On Sat, Sep 13, 2014 at 2:32 PM, Nolan Nichols > wrote: >> >> Hi, >> >> I'm curious if it is yet possible to edit the Notebook Metadata >> programatically. I'm familiar with how to do this in the UI manually, but >> would like to simply inject some json into the metadata using code. Thanks! >> >> Cheers, >> >> Nolan >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > From benjaminrk at gmail.com Sat Sep 13 22:49:44 2014 From: benjaminrk at gmail.com (MinRK) Date: Sat, 13 Sep 2014 19:49:44 -0700 Subject: [IPython-dev] API to Modify Notebook Metadata In-Reply-To: References: Message-ID: On Sat, Sep 13, 2014 at 6:42 PM, Wes Turner wrote: > Could this functionality be used for storing JSON-LD metadata which > maps to dcterms and/or schema.org? > > * Python: pyld, rdflib-jsonld > * Javscript: > http://www.w3.org/community/rdfjs/wiki/Comparison_of_RDFJS_libraries > > ... It would be great to be able to index notebooks by datasets referenced. > You can put anything JSONable in the metadata, so I imagine so. > -- > Wes Turner > > > On Sat, Sep 13, 2014 at 4:55 PM, MinRK wrote: > > It?s relatively straightforward to do this from Javascript: > > > > IPython.notebook.metadata.key = "value"; > > > > There isn?t an API to use from Python, other than raw execution of the > above > > javascript: > > > > from IPython.display import display_javascript > > display_javascript('IPython.notebook.metadata.key = "value";', raw=True) > > > > -MinRK > > > > > > On Sat, Sep 13, 2014 at 2:32 PM, Nolan Nichols > > wrote: > >> > >> Hi, > >> > >> I'm curious if it is yet possible to edit the Notebook Metadata > >> programatically. I'm familiar with how to do this in the UI manually, > but > >> would like to simply inject some json into the metadata using code. > Thanks! > >> > >> Cheers, > >> > >> Nolan > >> > >> _______________________________________________ > >> IPython-dev mailing list > >> IPython-dev at scipy.org > >> http://mail.scipy.org/mailman/listinfo/ipython-dev > >> > > > > > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: From jason-sage at creativetrax.com Sat Sep 13 23:51:03 2014 From: jason-sage at creativetrax.com (Jason Grout) Date: Sat, 13 Sep 2014 23:51:03 -0400 Subject: [IPython-dev] API to Modify Notebook Metadata In-Reply-To: References: Message-ID: <541510A7.6070306@creativetrax.com> On 9/13/14, 17:55, MinRK wrote: > It?s relatively straightforward to do this from Javascript: > > |IPython.notebook.metadata.key ="value"; > | > > There isn?t an API to use from Python, other than raw execution of the > above javascript: > > |from IPython.displayimport display_javascript > display_javascript('IPython.notebook.metadata.key = "value";', raw=True) > | > That display_javascript won't work once the iframe security mechanisms are introduced, will it? I think it would be really useful to have a natural way to access/modify the notebook metadata dict from python. Or more generally, a way to store some metadata information about the current session that should be available the next time this code is run or be available as part of the metadata for the current "document" of code (whatever that means in the current context). Perhaps we could have something like having get_ipython().notebook.metadata be an eventful dict that synchronizes with the javascript. I know this discussion of whether the kernel should be aware of the frontend has come up before in various contexts, and I think it will keep coming up. Jason From bussonniermatthias at gmail.com Sun Sep 14 03:25:07 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Sun, 14 Sep 2014 09:25:07 +0200 Subject: [IPython-dev] API to Modify Notebook Metadata In-Reply-To: <541510A7.6070306@creativetrax.com> References: <541510A7.6070306@creativetrax.com> Message-ID: <25AE40D1-DFD8-4361-AF5F-7C857FB4973B@gmail.com> I suppose the answer will be that the kernel does not know it is runned from a notebook, so no, no python API to manipulate the document. Storing provenance of data files and library is out of scope for IPython. Have a look at Konrad hinsen active paper that is made to do that and work with notebook. Envoy? de mon iPhone > Le 14 sept. 2014 ? 05:51, Jason Grout a ?crit : > > > >> On 9/13/14, 17:55, MinRK wrote: >> It?s relatively straightforward to do this from Javascript: >> >> |IPython.notebook.metadata.key ="value"; >> | >> >> There isn?t an API to use from Python, other than raw execution of the >> above javascript: >> >> |from IPython.displayimport display_javascript >> display_javascript('IPython.notebook.metadata.key = "value";', raw=True) >> | > > > That display_javascript won't work once the iframe security mechanisms > are introduced, will it? I think it would be really useful to have a > natural way to access/modify the notebook metadata dict from python. Or > more generally, a way to store some metadata information about the > current session that should be available the next time this code is run > or be available as part of the metadata for the current "document" of > code (whatever that means in the current context). > > Perhaps we could have something like having > get_ipython().notebook.metadata be an eventful dict that synchronizes > with the javascript. > > I know this discussion of whether the kernel should be aware of the > frontend has come up before in various contexts, and I think it will > keep coming up. > > Jason > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From Stephan.Sahm at gmx.de Sun Sep 14 04:44:04 2014 From: Stephan.Sahm at gmx.de (Stephan Sahm) Date: Sun, 14 Sep 2014 10:44:04 +0200 Subject: [IPython-dev] several bugs in ipython nbconvert --to latex In-Reply-To: References: <6DA11D77-5DE3-4CB0-AE9B-12B86101DB8A@gmail.com> Message-ID: I would be glad if these bugs become tracked =) On 12 September 2014 20:39, Fernando Perez wrote: > Quick q: is this captured in a bug report somewhere? Otherwise we'll lose > track of it... > > > On Thu, Sep 11, 2014 at 2:09 PM, Brian Granger > wrote: > >> Thanks I had noticed these problems as well >> >> Sent from my iPhone >> >> On Sep 11, 2014, at 12:46 PM, Stephan Sahm wrote: >> >> Dear all, >> >> today "ipython nbconvert --to pdf" didn't worked on my ipython notebook. >> I spend some hours to break the errors down and surprisingly found a whole >> bunch of bugs in the conversion from the notebook to the latex >> representation (at least compared to the html version). >> >> I made a little notebook with the example cases and descriptions how far >> I understood the bugs. >> It would be great if someone who knows how to fix those can do so for the >> next release. >> >> I used the current git-version from ipython (11.09.2014, branch master) >> on Ubuntu 14.04. (I used texlive-full as latex) >> >> As I now understand how to circumvent the gaps, I can use the latex >> conversion perfectly, but nevertheless I think those bugs deserve to be >> fixed. >> >> One feature request to the end: if the latex conversion works right, it >> would be great to have a kind of "export as..." menu-entry in a future >> ipython notebook to select several formats like especially latex and >> pdf(through latex). >> >> hoping for some reply, >> >> with best wishes, >> >> Stephan >> >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > > -- > Fernando Perez (@fperez_org; http://fperez.org) > fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) > fernando.perez-at-berkeley: contact me here for any direct mail > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bussonniermatthias at gmail.com Sun Sep 14 05:30:31 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Sun, 14 Sep 2014 11:30:31 +0200 Subject: [IPython-dev] several bugs in ipython nbconvert --to latex In-Reply-To: References: <6DA11D77-5DE3-4CB0-AE9B-12B86101DB8A@gmail.com> Message-ID: <6C3717C1-417D-4C21-A5DF-269B5A6B1C68@gmail.com> Le 14 sept. 2014 ? 10:44, Stephan Sahm a ?crit : > I would be glad if these bugs become tracked =) You can open as many issues as there are bugs on github : https://github.com/ipython/ipython/issues Click new issues on the top-right. If you don't have (and don't want) a github account, just tell us here and we'll do it for you. -- M > > On 12 September 2014 20:39, Fernando Perez wrote: > Quick q: is this captured in a bug report somewhere? Otherwise we'll lose track of it... > > > On Thu, Sep 11, 2014 at 2:09 PM, Brian Granger wrote: > Thanks I had noticed these problems as well > > Sent from my iPhone > > On Sep 11, 2014, at 12:46 PM, Stephan Sahm wrote: > >> Dear all, >> >> today "ipython nbconvert --to pdf" didn't worked on my ipython notebook. I spend some hours to break the errors down and surprisingly found a whole bunch of bugs in the conversion from the notebook to the latex representation (at least compared to the html version). >> >> I made a little notebook with the example cases and descriptions how far I understood the bugs. >> It would be great if someone who knows how to fix those can do so for the next release. >> >> I used the current git-version from ipython (11.09.2014, branch master) on Ubuntu 14.04. (I used texlive-full as latex) >> >> As I now understand how to circumvent the gaps, I can use the latex conversion perfectly, but nevertheless I think those bugs deserve to be fixed. >> >> One feature request to the end: if the latex conversion works right, it would be great to have a kind of "export as..." menu-entry in a future ipython notebook to select several formats like especially latex and pdf(through latex). >> >> hoping for some reply, >> >> with best wishes, >> >> Stephan >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > > -- > Fernando Perez (@fperez_org; http://fperez.org) > fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) > fernando.perez-at-berkeley: contact me here for any direct mail > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: From Stephan.Sahm at gmx.de Sun Sep 14 07:44:08 2014 From: Stephan.Sahm at gmx.de (Stephan Sahm) Date: Sun, 14 Sep 2014 13:44:08 +0200 Subject: [IPython-dev] several bugs in ipython nbconvert --to latex In-Reply-To: <6C3717C1-417D-4C21-A5DF-269B5A6B1C68@gmail.com> References: <6DA11D77-5DE3-4CB0-AE9B-12B86101DB8A@gmail.com> <6C3717C1-417D-4C21-A5DF-269B5A6B1C68@gmail.com> Message-ID: thanks for the help, actually, I know about github's issue system and also have a github account I indeed first thought about posting the bug there, however github does not support the attachment of arbitrary files (only images). Because the latex_bug_report.tar.gz is indeed the main part of the bug-report, I therefore chose the mailinglist to report it. a way I could imagine to make a github issue out of it is to reduce it to the notebooks text, ignoring the pdf and latex files, but is this how it is usually done? best, Stephan On 14 September 2014 11:30, Matthias Bussonnier < bussonniermatthias at gmail.com> wrote: > > Le 14 sept. 2014 ? 10:44, Stephan Sahm a ?crit : > > I would be glad if these bugs become tracked =) > > > You can open as many issues as there are bugs on github : > > https://github.com/ipython/ipython/issues > > Click new issues on the top-right. > > If you don't have (and don't want) a github account, just tell us here and > we'll do it for you. > > -- > M > > > On 12 September 2014 20:39, Fernando Perez wrote: > >> Quick q: is this captured in a bug report somewhere? Otherwise we'll lose >> track of it... >> >> >> On Thu, Sep 11, 2014 at 2:09 PM, Brian Granger >> wrote: >> >>> Thanks I had noticed these problems as well >>> >>> Sent from my iPhone >>> >>> On Sep 11, 2014, at 12:46 PM, Stephan Sahm wrote: >>> >>> Dear all, >>> >>> today "ipython nbconvert --to pdf" didn't worked on my ipython notebook. >>> I spend some hours to break the errors down and surprisingly found a whole >>> bunch of bugs in the conversion from the notebook to the latex >>> representation (at least compared to the html version). >>> >>> I made a little notebook with the example cases and descriptions how far >>> I understood the bugs. >>> It would be great if someone who knows how to fix those can do so for >>> the next release. >>> >>> I used the current git-version from ipython (11.09.2014, branch master) >>> on Ubuntu 14.04. (I used texlive-full as latex) >>> >>> As I now understand how to circumvent the gaps, I can use the latex >>> conversion perfectly, but nevertheless I think those bugs deserve to be >>> fixed. >>> >>> One feature request to the end: if the latex conversion works right, it >>> would be great to have a kind of "export as..." menu-entry in a future >>> ipython notebook to select several formats like especially latex and >>> pdf(through latex). >>> >>> hoping for some reply, >>> >>> with best wishes, >>> >>> Stephan >>> >>> >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> >> >> -- >> Fernando Perez (@fperez_org; http://fperez.org) >> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) >> fernando.perez-at-berkeley: contact me here for any direct mail >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bussonniermatthias at gmail.com Sun Sep 14 07:49:43 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Sun, 14 Sep 2014 13:49:43 +0200 Subject: [IPython-dev] several bugs in ipython nbconvert --to latex In-Reply-To: References: <6DA11D77-5DE3-4CB0-AE9B-12B86101DB8A@gmail.com> <6C3717C1-417D-4C21-A5DF-269B5A6B1C68@gmail.com> Message-ID: Le 14 sept. 2014 ? 13:44, Stephan Sahm a ?crit : > thanks for the help, > > actually, I know about github's issue system and also have a github account > I indeed first thought about posting the bug there, however github does not support the attachment of arbitrary files (only images). Because the latex_bug_report.tar.gz is indeed the main part of the bug-report, I therefore chose the mailinglist to report it. > > a way I could imagine to make a github issue out of it is to reduce it to the notebooks text, ignoring the pdf and latex files, but is this how it is usually done? Usually if you have external file you can great a gist on github and upload your files by drag-and-drop. then you add a link to your gist in the issue. Nice thing with gist is that as they are git repo, you can update the examples as you narrow the causes. -- M > > best, > Stephan > > On 14 September 2014 11:30, Matthias Bussonnier wrote: > > Le 14 sept. 2014 ? 10:44, Stephan Sahm a ?crit : > >> I would be glad if these bugs become tracked =) > > You can open as many issues as there are bugs on github : > > https://github.com/ipython/ipython/issues > > Click new issues on the top-right. > > If you don't have (and don't want) a github account, just tell us here and we'll do it for you. > > -- > M > >> >> On 12 September 2014 20:39, Fernando Perez wrote: >> Quick q: is this captured in a bug report somewhere? Otherwise we'll lose track of it... >> >> >> On Thu, Sep 11, 2014 at 2:09 PM, Brian Granger wrote: >> Thanks I had noticed these problems as well >> >> Sent from my iPhone >> >> On Sep 11, 2014, at 12:46 PM, Stephan Sahm wrote: >> >>> Dear all, >>> >>> today "ipython nbconvert --to pdf" didn't worked on my ipython notebook. I spend some hours to break the errors down and surprisingly found a whole bunch of bugs in the conversion from the notebook to the latex representation (at least compared to the html version). >>> >>> I made a little notebook with the example cases and descriptions how far I understood the bugs. >>> It would be great if someone who knows how to fix those can do so for the next release. >>> >>> I used the current git-version from ipython (11.09.2014, branch master) on Ubuntu 14.04. (I used texlive-full as latex) >>> >>> As I now understand how to circumvent the gaps, I can use the latex conversion perfectly, but nevertheless I think those bugs deserve to be fixed. >>> >>> One feature request to the end: if the latex conversion works right, it would be great to have a kind of "export as..." menu-entry in a future ipython notebook to select several formats like especially latex and pdf(through latex). >>> >>> hoping for some reply, >>> >>> with best wishes, >>> >>> Stephan >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> >> >> >> -- >> Fernando Perez (@fperez_org; http://fperez.org) >> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) >> fernando.perez-at-berkeley: contact me here for any direct mail >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: From fperez.net at gmail.com Sun Sep 14 13:50:40 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Sun, 14 Sep 2014 10:50:40 -0700 Subject: [IPython-dev] API to Modify Notebook Metadata In-Reply-To: <541510A7.6070306@creativetrax.com> References: <541510A7.6070306@creativetrax.com> Message-ID: On Sat, Sep 13, 2014 at 8:51 PM, Jason Grout wrote: > I know this discussion of whether the kernel should be aware of the > frontend has come up before in various contexts, and I think it will > keep coming up. > Absolutely. We even had it as a top-level topic for the last hands-on dev meeting, but sadly we ran out of time. This is something that we really need to find a better answer for, but it's a pretty delicate balancing act, as any 'quick hack' solution will break enough assumptions throughout our architecture to cause real problems elsewhere. And yet, it's a very valid and important request. We simply haven't had the bandwidth to tackle it directly, sad to say. -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: From benjaminrk at gmail.com Sun Sep 14 13:57:35 2014 From: benjaminrk at gmail.com (MinRK) Date: Sun, 14 Sep 2014 10:57:35 -0700 Subject: [IPython-dev] API to Modify Notebook Metadata In-Reply-To: <541510A7.6070306@creativetrax.com> References: <541510A7.6070306@creativetrax.com> Message-ID: On Sat, Sep 13, 2014 at 8:51 PM, Jason Grout wrote: > > > On 9/13/14, 17:55, MinRK wrote: > > It?s relatively straightforward to do this from Javascript: > > > > |IPython.notebook.metadata.key ="value"; > > | > > > > There isn?t an API to use from Python, other than raw execution of the > > above javascript: > > > > |from IPython.displayimport display_javascript > > display_javascript('IPython.notebook.metadata.key = "value";', raw=True) > > | > > > > > That display_javascript won't work once the iframe security mechanisms > are introduced, will it? I think it would be really useful to have a > natural way to access/modify the notebook metadata dict from python. Or > more generally, a way to store some metadata information about the > current session that should be available the next time this code is run > or be available as part of the metadata for the current "document" of > code (whatever that means in the current context). > It remains unclear whether iframes are going to work out at all. In any case, we probably will want to preserve access to the notebook document structure in javascript in some way. > > Perhaps we could have something like having > get_ipython().notebook.metadata be an eventful dict that synchronizes > with the javascript. > I know this discussion of whether the kernel should be aware of the > frontend has come up before in various contexts, and I think it will > keep coming up. > It does indeed. Still no decision on whether we should break the model yet, but we keep talking about it. > > Jason > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: From nolan.nichols at gmail.com Sun Sep 14 14:29:07 2014 From: nolan.nichols at gmail.com (nicholsn) Date: Sun, 14 Sep 2014 11:29:07 -0700 (PDT) Subject: [IPython-dev] API to Modify Notebook Metadata In-Reply-To: References: <541510A7.6070306@creativetrax.com> Message-ID: <1410719347782-5071571.post@n6.nabble.com> Thanks for the example, Min - worked perfectly. How would I go about retrieving a dict of the metadata I just set? WRT other comments in the thread, easy access to metadata i/o would be really useful - actually Wes hit my use case spot on, as I am storing provenance information as json-ld using the python PROV library (http://prov.readthedocs.org). As google and others increase support for vocabularies like schema.org, etc., I'd imagine improved indexing of notebooks, particularly if nbconvert embeds metadata as linked data (e.g., http://www.w3.org/TR/json-ld/#embedding-json-ld-in-html-documents). -- View this message in context: http://python.6.x6.nabble.com/API-to-Modify-Notebook-Metadata-tp5071535p5071571.html Sent from the IPython - Development mailing list archive at Nabble.com. From Stephan.Sahm at gmx.de Sun Sep 14 17:45:39 2014 From: Stephan.Sahm at gmx.de (Stephan Sahm) Date: Sun, 14 Sep 2014 23:45:39 +0200 Subject: [IPython-dev] several bugs in ipython nbconvert --to latex In-Reply-To: References: <6DA11D77-5DE3-4CB0-AE9B-12B86101DB8A@gmail.com> <6C3717C1-417D-4C21-A5DF-269B5A6B1C68@gmail.com> Message-ID: ok I created a new issue #6466 (pdf files are still not possible to be included as far as I see) thanks for the help On 14 September 2014 13:49, Matthias Bussonnier < bussonniermatthias at gmail.com> wrote: > > Le 14 sept. 2014 ? 13:44, Stephan Sahm a ?crit : > > thanks for the help, > > actually, I know about github's issue system and also have a github account > I indeed first thought about posting the bug there, however github does > not support the attachment of arbitrary files (only images). Because the > latex_bug_report.tar.gz is indeed the main part of the bug-report, I > therefore chose the mailinglist to report it. > > a way I could imagine to make a github issue out of it is to reduce it to > the notebooks text, ignoring the pdf and latex files, but is this how it is > usually done? > > > Usually if you have external file you can great a gist on github and > upload your files by drag-and-drop. > then you add a link to your gist in the issue. > > Nice thing with gist is that as they are git repo, you can update the > examples as you narrow the causes. > -- > M > > > > best, > Stephan > > On 14 September 2014 11:30, Matthias Bussonnier < > bussonniermatthias at gmail.com> wrote: > >> >> Le 14 sept. 2014 ? 10:44, Stephan Sahm a ?crit : >> >> I would be glad if these bugs become tracked =) >> >> >> You can open as many issues as there are bugs on github : >> >> https://github.com/ipython/ipython/issues >> >> Click new issues on the top-right. >> >> If you don't have (and don't want) a github account, just tell us here >> and we'll do it for you. >> >> -- >> M >> >> >> On 12 September 2014 20:39, Fernando Perez wrote: >> >>> Quick q: is this captured in a bug report somewhere? Otherwise we'll >>> lose track of it... >>> >>> >>> On Thu, Sep 11, 2014 at 2:09 PM, Brian Granger >>> wrote: >>> >>>> Thanks I had noticed these problems as well >>>> >>>> Sent from my iPhone >>>> >>>> On Sep 11, 2014, at 12:46 PM, Stephan Sahm wrote: >>>> >>>> Dear all, >>>> >>>> today "ipython nbconvert --to pdf" didn't worked on my ipython >>>> notebook. I spend some hours to break the errors down and surprisingly >>>> found a whole bunch of bugs in the conversion from the notebook to the >>>> latex representation (at least compared to the html version). >>>> >>>> I made a little notebook with the example cases and descriptions how >>>> far I understood the bugs. >>>> It would be great if someone who knows how to fix those can do so for >>>> the next release. >>>> >>>> I used the current git-version from ipython (11.09.2014, branch master) >>>> on Ubuntu 14.04. (I used texlive-full as latex) >>>> >>>> As I now understand how to circumvent the gaps, I can use the latex >>>> conversion perfectly, but nevertheless I think those bugs deserve to be >>>> fixed. >>>> >>>> One feature request to the end: if the latex conversion works right, it >>>> would be great to have a kind of "export as..." menu-entry in a future >>>> ipython notebook to select several formats like especially latex and >>>> pdf(through latex). >>>> >>>> hoping for some reply, >>>> >>>> with best wishes, >>>> >>>> Stephan >>>> >>>> >>>> >>>> _______________________________________________ >>>> IPython-dev mailing list >>>> IPython-dev at scipy.org >>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>> >>>> >>>> _______________________________________________ >>>> IPython-dev mailing list >>>> IPython-dev at scipy.org >>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>> >>>> >>> >>> >>> -- >>> Fernando Perez (@fperez_org; http://fperez.org) >>> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) >>> fernando.perez-at-berkeley: contact me here for any direct mail >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bussonniermatthias at gmail.com Mon Sep 15 03:08:04 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Mon, 15 Sep 2014 09:08:04 +0200 Subject: [IPython-dev] several bugs in ipython nbconvert --to latex In-Reply-To: References: <6DA11D77-5DE3-4CB0-AE9B-12B86101DB8A@gmail.com> <6C3717C1-417D-4C21-A5DF-269B5A6B1C68@gmail.com> Message-ID: <87610123-41FB-4A63-A977-35A1B5C65A3B@gmail.com> Thanks! Envoy? de mon iPhone > Le 14 sept. 2014 ? 23:45, Stephan Sahm a ?crit : > > ok I created a new issue #6466 > (pdf files are still not possible to be included as far as I see) > > thanks for the help > >> On 14 September 2014 13:49, Matthias Bussonnier wrote: >> >>> Le 14 sept. 2014 ? 13:44, Stephan Sahm a ?crit : >>> >>> thanks for the help, >>> >>> actually, I know about github's issue system and also have a github account >>> I indeed first thought about posting the bug there, however github does not support the attachment of arbitrary files (only images). Because the latex_bug_report.tar.gz is indeed the main part of the bug-report, I therefore chose the mailinglist to report it. >>> >>> a way I could imagine to make a github issue out of it is to reduce it to the notebooks text, ignoring the pdf and latex files, but is this how it is usually done? >> >> Usually if you have external file you can great a gist on github and upload your files by drag-and-drop. >> then you add a link to your gist in the issue. >> >> Nice thing with gist is that as they are git repo, you can update the examples as you narrow the causes. >> -- >> M >> >> >>> >>> best, >>> Stephan >>> >>>> On 14 September 2014 11:30, Matthias Bussonnier wrote: >>>> >>>>> Le 14 sept. 2014 ? 10:44, Stephan Sahm a ?crit : >>>>> >>>>> I would be glad if these bugs become tracked =) >>>> >>>> You can open as many issues as there are bugs on github : >>>> >>>> https://github.com/ipython/ipython/issues >>>> >>>> Click new issues on the top-right. >>>> >>>> If you don't have (and don't want) a github account, just tell us here and we'll do it for you. >>>> >>>> -- >>>> M >>>> >>>>> >>>>>> On 12 September 2014 20:39, Fernando Perez wrote: >>>>>> Quick q: is this captured in a bug report somewhere? Otherwise we'll lose track of it... >>>>>> >>>>>> >>>>>>> On Thu, Sep 11, 2014 at 2:09 PM, Brian Granger wrote: >>>>>>> Thanks I had noticed these problems as well >>>>>>> >>>>>>> Sent from my iPhone >>>>>>> >>>>>>>> On Sep 11, 2014, at 12:46 PM, Stephan Sahm wrote: >>>>>>>> >>>>>>>> Dear all, >>>>>>>> >>>>>>>> today "ipython nbconvert --to pdf" didn't worked on my ipython notebook. I spend some hours to break the errors down and surprisingly found a whole bunch of bugs in the conversion from the notebook to the latex representation (at least compared to the html version). >>>>>>>> >>>>>>>> I made a little notebook with the example cases and descriptions how far I understood the bugs. >>>>>>>> It would be great if someone who knows how to fix those can do so for the next release. >>>>>>>> >>>>>>>> I used the current git-version from ipython (11.09.2014, branch master) on Ubuntu 14.04. (I used texlive-full as latex) >>>>>>>> >>>>>>>> As I now understand how to circumvent the gaps, I can use the latex conversion perfectly, but nevertheless I think those bugs deserve to be fixed. >>>>>>>> >>>>>>>> One feature request to the end: if the latex conversion works right, it would be great to have a kind of "export as..." menu-entry in a future ipython notebook to select several formats like especially latex and pdf(through latex). >>>>>>>> >>>>>>>> hoping for some reply, >>>>>>>> >>>>>>>> with best wishes, >>>>>>>> >>>>>>>> Stephan >>>>>>>> >>>>>>>> _______________________________________________ >>>>>>>> IPython-dev mailing list >>>>>>>> IPython-dev at scipy.org >>>>>>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>>>>> >>>>>>> _______________________________________________ >>>>>>> IPython-dev mailing list >>>>>>> IPython-dev at scipy.org >>>>>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>>>> >>>>>> >>>>>> >>>>>> -- >>>>>> Fernando Perez (@fperez_org; http://fperez.org) >>>>>> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) >>>>>> fernando.perez-at-berkeley: contact me here for any direct mail >>>>>> >>>>>> _______________________________________________ >>>>>> IPython-dev mailing list >>>>>> IPython-dev at scipy.org >>>>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>>> >>>>> _______________________________________________ >>>>> IPython-dev mailing list >>>>> IPython-dev at scipy.org >>>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>> >>>> >>>> _______________________________________________ >>>> IPython-dev mailing list >>>> IPython-dev at scipy.org >>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: From a.h.jaffe at gmail.com Mon Sep 15 11:12:22 2014 From: a.h.jaffe at gmail.com (Andrew Jaffe) Date: Mon, 15 Sep 2014 16:12:22 +0100 Subject: [IPython-dev] notebook startup template (not exec_lines) Message-ID: <541701D6.3060605@gmail.com> Hi all, Is there any way to automatically include some boilerplate cell or cells in a notebook when it is created? I know that I can automatically run some commands with c.IPKernelApp.exec_lines = [...] but I would actually like to have the code included in a cell (executed or unexecuted) at the top of the notebook (so that users on other machines can have the same code in their notebooks). I thought I saw a related question at some point recently, but I can't find it. Andrew From takowl at gmail.com Mon Sep 15 12:21:17 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Mon, 15 Sep 2014 09:21:17 -0700 Subject: [IPython-dev] notebook startup template (not exec_lines) In-Reply-To: <541701D6.3060605@gmail.com> References: <541701D6.3060605@gmail.com> Message-ID: You can probably hack something to do it in custom.js, but we don't have any notion of a default template for new notebooks. Thomas On 15 September 2014 08:12, Andrew Jaffe wrote: > Hi all, > > Is there any way to automatically include some boilerplate cell or cells > in a notebook when it is created? > > I know that I can automatically run some commands with > c.IPKernelApp.exec_lines = [...] > but I would actually like to have the code included in a cell (executed > or unexecuted) at the top of the notebook (so that users on other > machines can have the same code in their notebooks). > > I thought I saw a related question at some point recently, but I can't > find it. > > Andrew > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: From hughesadam87 at gmail.com Mon Sep 15 14:42:19 2014 From: hughesadam87 at gmail.com (hugadams) Date: Mon, 15 Sep 2014 11:42:19 -0700 (PDT) Subject: [IPython-dev] Feasilibity of widgets/layout for mimicking this In-Reply-To: References: <1408298099961-5068197.post@n6.nabble.com> Message-ID: Hi Nicholas, I wanted to followup and ask if you had furthered this work anymore, or come up with some complete examples of its implementation that you could perhaps share with us? We are at the point where we're going to delve into this in earnest and really want to use your framework. If you have any complete example notebooks developed with these tools, would it be possible to share? Thanks On Wed, Aug 27, 2014 at 10:52 PM, Nicholas Bollweg [via Python] < ml-node+s6n5069446h88 at n6.nabble.com> wrote: > I was suggesting (with the naming) that e would be updated by a changing, > but I agree, it's confusing. > > I tried something more complicated with kwargs, but it ended up being a > whole second implementation of the thing that Wire does, which seemed like > too much, but would look like this (which I think is somewhat more > readable): > > @wire(wire.e.value, a=wire.a.value)def thrice(a): > return a * 3 > > > I've updated to use that, as well as an example of the dictionary-based > assignment it is using. I welcome any other suggestions: the decorator > syntax is somewhat limiting, which is probably good as this is already > really evil :) > > On Wed, Aug 27, 2014 at 7:47 PM, hugadams <[hidden email] > > wrote: > >> These are def cool. Can you keep me updated if you add more to this? >> I'd like to steal it (with credit) for our widgets. >> >> One question about the decorator: >> >> @wire(wire.e.value, wire.a.value)def thrice(a): >> return a * 3 >> >> >> Does this mean that anytime the "e" widget value is changed, the "a" >> widget value will be multiplied by 3? Or am I not understanding what is >> happening here? >> >> On Wed, Aug 27, 2014 at 6:24 PM, Nicholas Bollweg [via Python] <[hidden >> email] > wrote: >> >>> Adam: >>> It's really no problem... this is exactly the way we want to be building >>> engineering tools at work, so it's been beneficial to have a more-defined >>> problem than "make interactive dashboards better/faster/stronger". >>> >>> I really dug into the 3.0 notebook over the weekend, and do find it a >>> bit nicer. >>> >>> Also, your decorator made me want some similar stuff, so I hacked >>> together these two classes: >>> >>> http://nbviewer.ipython.org/gist/bollwyvl/8001ed62c6868301c26e >>>> >>> >>> again, no widget actually show up, but I think one gets the idea. >>> >>> it does provide a decorator (I'm not happy with it yet) as well as >>> overloaded assignment and transformed values. I hope this might be useful! >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> [hidden email] >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >>> ------------------------------ >>> If you reply to this email, your message will be added to the >>> discussion below: >>> >>> http://python.6.x6.nabble.com/Feasilibity-of-widgets-layout-for-mimicking-this-tp5068197p5069419.html >>> To unsubscribe from Feasilibity of widgets/layout for mimicking this, click >>> here. >>> NAML >>> >>> >> >> >> ------------------------------ >> View this message in context: Re: Feasilibity of widgets/layout for >> mimicking this >> >> Sent from the IPython - Development mailing list archive >> at >> Nabble.com. >> >> _______________________________________________ >> IPython-dev mailing list >> [hidden email] >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > [hidden email] > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > ------------------------------ > If you reply to this email, your message will be added to the discussion > below: > > http://python.6.x6.nabble.com/Feasilibity-of-widgets-layout-for-mimicking-this-tp5068197p5069446.html > To unsubscribe from Feasilibity of widgets/layout for mimicking this, click > here > > . > NAML > > -- View this message in context: http://python.6.x6.nabble.com/Feasilibity-of-widgets-layout-for-mimicking-this-tp5068197p5071629.html Sent from the IPython - Development mailing list archive at Nabble.com. -------------- next part -------------- An HTML attachment was scrubbed... URL: From bobd at stanford.edu Mon Sep 15 15:13:41 2014 From: bobd at stanford.edu (Bob Dougherty) Date: Mon, 15 Sep 2014 12:13:41 -0700 Subject: [IPython-dev] Jupyterhub with ssl? Message-ID: <54173A65.6020904@stanford.edu> Hi All, Is anyone else running Jupyterhub through ssl? I'm struggling to get it working. Everything works fine except for the websocket connection. I.e., I can log in through the Jupyterhub login page, create, edit, save notebooks, etc. But trying to execute a code cell just hangs. Chrome shows this in the js console: Default extension for cell metadata editing loaded. Raw Cell Format toolbar preset loaded. Slideshow extension for metadata editing loaded. Kernel started: 398fe67c-856b-48c5-b2d7-242bfa70f2e1 Starting WebSockets: wss://spgr.stanford.edu:8080/user/bobd/api/kernels/398fe67c-856b-48c5-b2d7-242bfa70f2e1 Uncaught InvalidStateError: Failed to execute 'send' on 'WebSocket': Still in CONNECTING state. :8080/user/bobd/static/services/kernels/js/kernel.js:248 Everything *does* work when I don't use ssl, and ssl works (with the same cert and key) when I run the notebook directly without jupyterhub. So I suspect it's a problem with the nodejs proxy of wss. I'm running node v0.10.25 and the current master of jupyterhub and ipython. Any help on debugging this would be much appreciated! thanks, bob -------------- next part -------------- An HTML attachment was scrubbed... URL: From bussonniermatthias at gmail.com Mon Sep 15 15:19:52 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Mon, 15 Sep 2014 21:19:52 +0200 Subject: [IPython-dev] Jupyterhub with ssl? In-Reply-To: <54173A65.6020904@stanford.edu> References: <54173A65.6020904@stanford.edu> Message-ID: Le 15 sept. 2014 ? 21:13, Bob Dougherty a ?crit : > Hi All, > > Is anyone else running Jupyterhub through ssl? I'm struggling to get it working. Everything works fine except for the websocket connection. I.e., I can log in through the Jupyterhub login page, create, edit, save notebooks, etc. But trying to execute a code cell just hangs. Chrome shows this in the js console: > Default extension for cell metadata editing loaded. > Raw Cell Format toolbar preset loaded. > Slideshow extension for metadata editing loaded. > Kernel started: 398fe67c-856b-48c5-b2d7-242bfa70f2e1 > Starting WebSockets: wss://spgr.stanford.edu:8080/user/bobd/api/kernels/398fe67c-856b-48c5-b2d7-242bfa70f2e1 > Uncaught InvalidStateError: Failed to execute 'send' on 'WebSocket': Still in CONNECTING state. :8080/user/bobd/static/services/kernels/js/kernel.js:248 > Everything *does* work when I don't use ssl, and ssl works (with the same cert and key) when I run the notebook directly without jupyterhub. So I suspect it's a problem with the nodejs proxy of wss. I'm running node v0.10.25 and the current master of jupyterhub and ipython. > > Any help on debugging this would be much appreciated! I got that on chrome, without jupyter-hub. Solved by itself after 1 week of holidays. My opinion is that it's a bug on chrome that sometime refuses to open 3 web socket connexions at the same time, as when it did happen firefox was happy with my setup. -- M > > thanks, > bob > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: From bobd at stanford.edu Mon Sep 15 15:26:05 2014 From: bobd at stanford.edu (Bob Dougherty) Date: Mon, 15 Sep 2014 12:26:05 -0700 Subject: [IPython-dev] Jupyterhub with ssl? In-Reply-To: References: <54173A65.6020904@stanford.edu> Message-ID: <54173D4D.9020307@stanford.edu> Thanks Matthias. Unfortunately, I get the same error on Firefox. And ipython without the hub works fine with ssl on Chrome. Does ssl through jupyterhub work for you? If so, what version of node are you running? On 09/15/2014 12:19 PM, Matthias Bussonnier wrote: > > Le 15 sept. 2014 ? 21:13, Bob Dougherty > a ?crit : > >> Hi All, >> >> Is anyone else running Jupyterhub through ssl? I'm struggling to get >> it working. Everything works fine except for the websocket >> connection. I.e., I can log in through the Jupyterhub login page, >> create, edit, save notebooks, etc. But trying to execute a code cell >> just hangs. Chrome shows this in the js console: >> >> Default extension for cell metadata editing loaded. >> Raw Cell Format toolbar preset loaded. >> Slideshow extension for metadata editing loaded. >> Kernel started: 398fe67c-856b-48c5-b2d7-242bfa70f2e1 >> Starting WebSockets: >> wss://spgr.stanford.edu:8080/user/bobd/api/kernels/398fe67c-856b-48c5-b2d7-242bfa70f2e1 >> Uncaught InvalidStateError: Failed to execute 'send' on >> 'WebSocket': Still in CONNECTING state. >> :8080/user/bobd/static/services/kernels/js/kernel.js:248 >> >> Everything *does* work when I don't use ssl, and ssl works (with the >> same cert and key) when I run the notebook directly without >> jupyterhub. So I suspect it's a problem with the nodejs proxy of wss. >> I'm running node v0.10.25 and the current master of jupyterhub and >> ipython. >> >> Any help on debugging this would be much appreciated! > > I got that on chrome, without jupyter-hub. Solved by itself after 1 > week of holidays. > My opinion is that it's a bug on chrome that sometime refuses to open > 3 web socket connexions at the same time, > as when it did happen firefox was happy with my setup. > > -- > M > > >> >> thanks, >> bob >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: From benjaminrk at gmail.com Mon Sep 15 19:26:38 2014 From: benjaminrk at gmail.com (MinRK) Date: Mon, 15 Sep 2014 16:26:38 -0700 Subject: [IPython-dev] Jupyterhub with ssl? In-Reply-To: <54173D4D.9020307@stanford.edu> References: <54173A65.6020904@stanford.edu> <54173D4D.9020307@stanford.edu> Message-ID: I'll look into it. Might be something wrong in the proxy config. On Mon, Sep 15, 2014 at 12:26 PM, Bob Dougherty wrote: > Thanks Matthias. Unfortunately, I get the same error on Firefox. And > ipython without the hub works fine with ssl on Chrome. Does ssl through > jupyterhub work for you? If so, what version of node are you running? > > > On 09/15/2014 12:19 PM, Matthias Bussonnier wrote: > > > Le 15 sept. 2014 ? 21:13, Bob Dougherty a ?crit : > > Hi All, > > Is anyone else running Jupyterhub through ssl? I'm struggling to get it > working. Everything works fine except for the websocket connection. I.e., I > can log in through the Jupyterhub login page, create, edit, save notebooks, > etc. But trying to execute a code cell just hangs. Chrome shows this in the > js console: > > Default extension for cell metadata editing loaded. > Raw Cell Format toolbar preset loaded. > Slideshow extension for metadata editing loaded. > Kernel started: 398fe67c-856b-48c5-b2d7-242bfa70f2e1 > Starting WebSockets: > wss://spgr.stanford.edu:8080/user/bobd/api/kernels/398fe67c-856b-48c5-b2d7-242bfa70f2e1 > Uncaught InvalidStateError: Failed to execute 'send' on 'WebSocket': > Still in CONNECTING state. > :8080/user/bobd/static/services/kernels/js/kernel.js:248 > > Everything *does* work when I don't use ssl, and ssl works (with the same > cert and key) when I run the notebook directly without jupyterhub. So I > suspect it's a problem with the nodejs proxy of wss. I'm running node > v0.10.25 and the current master of jupyterhub and ipython. > > Any help on debugging this would be much appreciated! > > > I got that on chrome, without jupyter-hub. Solved by itself after 1 week > of holidays. > My opinion is that it's a bug on chrome that sometime refuses to open 3 > web socket connexions at the same time, > as when it did happen firefox was happy with my setup. > > -- > M > > > > thanks, > bob > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > > _______________________________________________ > IPython-dev mailing listIPython-dev at scipy.orghttp://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From benjaminrk at gmail.com Mon Sep 15 21:09:15 2014 From: benjaminrk at gmail.com (MinRK) Date: Mon, 15 Sep 2014 18:09:15 -0700 Subject: [IPython-dev] notebook startup template (not exec_lines) In-Reply-To: References: <541701D6.3060605@gmail.com> Message-ID: There are two main places you can do this: 1. in custom.js, you can check if the notebook is empty on load, and add the desired boilerplate. 2. subclass ContentsManager, and edit the code that makes a new notebook to copy a template notebook you specify, instead of creating an empty one. -MinRK On Mon, Sep 15, 2014 at 9:21 AM, Thomas Kluyver wrote: > You can probably hack something to do it in custom.js, but we don't have > any notion of a default template for new notebooks. > > Thomas > > On 15 September 2014 08:12, Andrew Jaffe wrote: > >> Hi all, >> >> Is there any way to automatically include some boilerplate cell or cells >> in a notebook when it is created? >> >> I know that I can automatically run some commands with >> c.IPKernelApp.exec_lines = [...] >> but I would actually like to have the code included in a cell (executed >> or unexecuted) at the top of the notebook (so that users on other >> machines can have the same code in their notebooks). >> >> I thought I saw a related question at some point recently, but I can't >> find it. >> >> Andrew >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From nick.bollweg at gmail.com Mon Sep 15 23:19:20 2014 From: nick.bollweg at gmail.com (Nicholas Bollweg) Date: Mon, 15 Sep 2014 23:19:20 -0400 Subject: [IPython-dev] Widget example that uses classes instead of globals? In-Reply-To: References: <-1189340719239998470@unknownmsgid> Message-ID: @antonino: I hadn't thought to use interact that way! __call__ might be too magic to be used that way... but you can create a non-bound function (not a method, though self would be in scope!) in the constructor of a widget that will respond to interact: from IPython.html.widgets import interact, ContainerWidget, HTMLWidget > > class Carousel(ContainerWidget): > def __init__(self, *args, **kwargs): > self.might_show = [HTMLWidget(value="

%s

" % i) for i in > range(10)] > super(Carousel, self).__init__(*args, **kwargs) > > def interact(n): > self.children = [self.might_show[n]] > > self.show = show > > carousel = Carousel() > interact(carousel.interact, n=(0, len(carousel.might_show)-1)) > carousel > I don't know much about how matplotlib interacts with widgets/traitlets... but presumably the ImageWidget will accept them as its value. You could move even more behavior into the class itself, but eventually one would likely need something more complicated than what interact provides out of the box... @adam: Sorry it took me a while to respond. Here is an updated version of the fake GUI, implemented as a series of classes: a standalone graph, a couple reusable control components and the full-blown end user GUI. I tried to put a few examples of different techniques in that we have used: link, on_trait_changed, CSS, Bootstrap. I didn't do any custom Backbone, as that is a whole other kettle of fish. > > http://nbviewer.ipython.org/gist/bollwyvl/ddd4bf5d7c879012fa2c > There are a few more gotchas that would come along with this, such as installing assets, if you end up using them, but there are a good number of threads/examples out there for install_nbextension/load_nbextensions. In a pinch, you could even cheat and have an HTML embed the style directly, I guess! I didn't use the "wire" concept from before: while it has proven useful for quickly hacking stuff together, i have found it might be a bit "cute" for something that one actually wanted to release and/or expect people to be able to extend. If i can figure out how to get it to easily un-listen for things, it might be work saving, but in the meantime link and on_trait_changed are good enough! Hope this helps! On Sat, Aug 30, 2014 at 2:21 PM, Antonino Ingargiola wrote: > Hi, > > Sorry for entering in the discussion on-fly... > > My question is more specific (but possibly very similar). Would be > possible to call interact with a class object (i.e. a callable class) > instead of a function? This would allow to store all the GUI specific state > in the class (for example precomputing figures) without the need of using > globals. > > When I quickly tried (with ipython 2.2), interact returned an error > complaining about the number of parameters passed to the object. So I > resorted to using globals. Below I attached the code I currently use to > pre-compute a set of figures (a slider selects which figure to display). I > would appreciate any comment on possibly improving this pattern. > > fig_cache = {} > def plot_mfit_i(ich=0, nodisplay=False): > global fig_cache > if ich not in fig_cache: > fig = mfit.plot_mfit(fitter, ich=ich, residuals=True, > return_fig=True) > fig_cache[ich] = fig > plt.close(fig) > if not nodisplay: > display(fig_cache[ich]) > > for i in range(8): plot_mfit_i(i, nodisplay=True) # Precompute all the > figures > > interact(plot_mfit_i, ich=(0, 7), nodisplay=fixed(False)); # display the > figure selected through the slider > > -- > Antonio > > On Sat, Aug 30, 2014 at 10:49 AM, Cyrille Rossant < > cyrille.rossant at gmail.com> wrote: > >> I think you can use the "display" function to render a widget instance, >> does that answer your question? >> ------------------------------ >> De : Adam Hughes >> Envoy? : ?30/?08/?2014 18:43 >> ? : IPython developers list >> Objet : Re: [IPython-dev] Widget example that uses classes instead of >> globals? >> >> And just to clarify, I presume that the notebook is actively "looking" >> for particular functions or something in the cell that let's the notebook >> know "hey, this is widget/GUI code, I need to output it as so". I had >> worried that if this critical piece was buried in a class, the notebook >> wouldn't recognize it, and the GUI wouldn't display. >> >> >> On Sat, Aug 30, 2014 at 1:41 PM, Adam Hughes >> wrote: >> >>> Hi, >>> >>> This question follows directly from this recent thread on the feasiblity >>> of widgets ( >>> http://python.6.x6.nabble.com/Feasilibity-of-widgets-layout-for-mimicking-this-td5068197.html) >>> but I thought was specific enough to be a new thread. >>> >>> In all of the notebook examples I've seen, a GUI is defined in its own >>> cell with global variables that are shared between functions. I'd really >>> like to see a complete, simple example of a GUI build as a class, where >>> most of the events, updates and default values are set within the class. >>> And then when the class is instantiated, the notebook somehow can still >>> output the GUI. >>> >>> For example, would something of this design be compatible with the >>> current widget design pattern: >>> >>> *class Foo(object):* >>> >>> * variable = defaultvalue* >>> >>> * def update_variable(self):* >>> * ....* >>> >>> * def redraw(self):* >>> * ...* >>> >>> *# Instantiate the class* >>> *f = Foo()* >>> *f.variable_widget.on_trait_change(update_variable, 'value')* >>> >>> Or is this type of design pattern out of the question? We're trying to >>> move in this direction so that we can compartmentalize and template as much >>> behavior as possible, and make a simple framework for building up more >>> complex GUIs. It's just now clear to me if such a pattern is possible. If >>> anyone has any insights or examples, would you mind sharing? >>> >>> THanks >>> >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From jason-sage at creativetrax.com Tue Sep 16 00:30:32 2014 From: jason-sage at creativetrax.com (Jason Grout) Date: Tue, 16 Sep 2014 00:30:32 -0400 Subject: [IPython-dev] eco: a composed language editor In-Reply-To: References: Message-ID: <5417BCE8.5080801@creativetrax.com> On 8/23/14, 13:52, Nicholas Bollweg wrote: > codemirror doesn't appear to support flowed widgets (yet?). Codemirror definitely supports arbitrary DOM elements inline with text. I've made several demos of inline widgets for graphical matrices or graphs, for example: http://bl.ocks.org/jasongrout/5378313. Thanks, Jason From hughesadam87 at gmail.com Tue Sep 16 13:43:30 2014 From: hughesadam87 at gmail.com (Adam Hughes) Date: Tue, 16 Sep 2014 13:43:30 -0400 Subject: [IPython-dev] Possible issues with submodule updates Message-ID: Hi, I just updated to the new dev version, and ran python setup.py submodule as usual, then setup.py install. When I open a notebook, either new or pre-made, I get a blank window. I get this error: WARNING:tornado.access:404 GET /static/jqueryui.js (127.0.0.1) 0.72ms referer=http://localhost:8890/notebooks/Untitled0.ipynb I've updated tornado, and nothing happens. I've reverted back to ipython 2.3 and I still get this. I'm on ubuntu. My friend is using mac osx 10.7. Her notebook actually loadas, but runs her first cell, regardless of what's in it, the kernel freezes. IE the cell's indicator changes to a " * " and stays like that. Is anyone else experiences such issues? Here is my pip freeze output (note pip freeze still says on on ipython 3.0, but if I run ipython in the terminal, it starts as 2.3: Canopy==1.4.0.dev6600 Cython==0.21 Examples==7.3 Flask==0.10.1 Jinja2==2.7.3 MKL==10.3 Markdown==2.4.1 MarkupSafe==0.23 PIL==1.1.7 PySide==1.2.1 PyYAML==3.11 Pygments==1.6.0 PythonDoc==2.7.3 Qt==4.8.5 Shapely==1.3.2 VTK==5.10.1 Werkzeug==0.9.6 appinst==2.1.2 apptools==4.2.1 atom==0.3.9 backports.ssl-match-hostname==3.4.0.2 basemap==1.0.7 bokeh==0.5.2 casuarius==1.1 certifi==14.05.14 chaco==4.4.1 cloud==2.4.6 colorama==0.3.1 configobj==5.0.6 coverage==3.7.1 docutils==0.11 enable==4.4.1 enaml==0.9.5 encore==0.5.1 enstaller==4.6.5 envisage==4.4.0 esky==0.9.8dev etsproxy==0.1.2 faulthandler==2.2 feedparser==5.1.3 freetype==2.5.3 geopandas==0.1.0.dev-35c2f5b gevent==1.0.1 gevent-websocket==0.9.3 glib==2.36.1 gnureadline==6.2.5 greenlet==0.4.3 grits-client==0.1 gst-plugins-bad==0.10.23 gst-plugins-base==0.10.36 gst-plugins-good==0.10.30 gstreamer==0.10.36 idle==2.7.3 ipython==3.0.0-dev itsdangerous==0.24 jdcal==1.0 jsonpickle==0.4.0 jsonpointer==1.4 jsonschema==2.3.0 kernmagic==0.2.0 keyring==3.6dev kiwisolver==0.1.2 libffi==3.0.13 libgfortran==3.0.0 libjpeg==7.0 libjpeg62==6.2 libncurses==5.9 libogg==1.3.0 libpng==1.6.12 libtheora==1.1.1 libvpx==1.1.0 libxml2==2.7.8 matplotlib==1.4.0 mayavi==4.3.1 mock==1.0.1 nbopen==0.1 nmrglue==0.4 nose==1.3.3 numpy==1.8.2 openpyxl==2.0.3 pandas==0.14.0 patsy==0.2.1 plotly==1.1.4 ply==3.4 psutil==1.2.1 pyaudio==0.2.4 pyface==4.4.0 pyflakes==0.7.3 pyglet==1.1.4 pyparsing==2.0.2 -e git+ https://github.com/hugadams/pyparty.git at e719a2c21d0e9ee32d36347792572bd61571de21#egg=pyparty-master pyproj==1.9.3 pysdmx==0.1 pystache==0.5.4 python-dateutil==2.2.0 pytz==2013b -e git+ https://github.com/hugadams/pyuvvis.git at a40befc64b0ac8a18d344d0e40b32b2b68dc3128#egg=pyuvvis-master pyzmq==14.3.1 readline==6.2.4.1 redis==2.10.3 requests==2.2.1 restview==2.0.5 runipy==0.1.0 scikit-learn==0.14.1 scikits.image==0.9.3 scipy==0.14.0 shiboken==1.2.1 six==1.7.3 ssl-match-hostname==3.4.0.2 statsmodels==0.5.0 supplement==0.5dev.dev202 svgwrite==1.1.2 sympy==0.7.5 tornado==4.0.2 traits==4.5.0 traitsui==4.4.0 websocket==0.2.1 wsgiref==0.1.2 wxPython==2.8.10.1 xray==0.1.1 zeromq==4.0.4 zlib==1.2.6 -------------- next part -------------- An HTML attachment was scrubbed... URL: From benjaminrk at gmail.com Tue Sep 16 13:55:02 2014 From: benjaminrk at gmail.com (MinRK) Date: Tue, 16 Sep 2014 10:55:02 -0700 Subject: [IPython-dev] Possible issues with submodule updates In-Reply-To: References: Message-ID: What do you get from git status and git submodule status? ? On Tue, Sep 16, 2014 at 10:43 AM, Adam Hughes wrote: > Hi, > > I just updated to the new dev version, and ran python setup.py submodule > as usual, then setup.py install. When I open a notebook, either new or > pre-made, I get a blank window. I get this error: > > WARNING:tornado.access:404 GET /static/jqueryui.js (127.0.0.1) 0.72ms > referer=http://localhost:8890/notebooks/Untitled0.ipynb > > I've updated tornado, and nothing happens. I've reverted back to ipython > 2.3 and I still get this. I'm on ubuntu. > > My friend is using mac osx 10.7. Her notebook actually loadas, but runs > her first cell, regardless of what's in it, the kernel freezes. IE the > cell's indicator changes to a " * " and stays like that. > > Is anyone else experiences such issues? > > Here is my pip freeze output (note pip freeze still says on on ipython > 3.0, but if I run ipython in the terminal, it starts as 2.3: > > Canopy==1.4.0.dev6600 > Cython==0.21 > Examples==7.3 > Flask==0.10.1 > Jinja2==2.7.3 > MKL==10.3 > Markdown==2.4.1 > MarkupSafe==0.23 > PIL==1.1.7 > PySide==1.2.1 > PyYAML==3.11 > Pygments==1.6.0 > PythonDoc==2.7.3 > Qt==4.8.5 > Shapely==1.3.2 > VTK==5.10.1 > Werkzeug==0.9.6 > appinst==2.1.2 > apptools==4.2.1 > atom==0.3.9 > backports.ssl-match-hostname==3.4.0.2 > basemap==1.0.7 > bokeh==0.5.2 > casuarius==1.1 > certifi==14.05.14 > chaco==4.4.1 > cloud==2.4.6 > colorama==0.3.1 > configobj==5.0.6 > coverage==3.7.1 > docutils==0.11 > enable==4.4.1 > enaml==0.9.5 > encore==0.5.1 > enstaller==4.6.5 > envisage==4.4.0 > esky==0.9.8dev > etsproxy==0.1.2 > faulthandler==2.2 > feedparser==5.1.3 > freetype==2.5.3 > geopandas==0.1.0.dev-35c2f5b > gevent==1.0.1 > gevent-websocket==0.9.3 > glib==2.36.1 > gnureadline==6.2.5 > greenlet==0.4.3 > grits-client==0.1 > gst-plugins-bad==0.10.23 > gst-plugins-base==0.10.36 > gst-plugins-good==0.10.30 > gstreamer==0.10.36 > idle==2.7.3 > ipython==3.0.0-dev > itsdangerous==0.24 > jdcal==1.0 > jsonpickle==0.4.0 > jsonpointer==1.4 > jsonschema==2.3.0 > kernmagic==0.2.0 > keyring==3.6dev > kiwisolver==0.1.2 > libffi==3.0.13 > libgfortran==3.0.0 > libjpeg==7.0 > libjpeg62==6.2 > libncurses==5.9 > libogg==1.3.0 > libpng==1.6.12 > libtheora==1.1.1 > libvpx==1.1.0 > libxml2==2.7.8 > matplotlib==1.4.0 > mayavi==4.3.1 > mock==1.0.1 > nbopen==0.1 > nmrglue==0.4 > nose==1.3.3 > numpy==1.8.2 > openpyxl==2.0.3 > pandas==0.14.0 > patsy==0.2.1 > plotly==1.1.4 > ply==3.4 > psutil==1.2.1 > pyaudio==0.2.4 > pyface==4.4.0 > pyflakes==0.7.3 > pyglet==1.1.4 > pyparsing==2.0.2 > -e git+ > https://github.com/hugadams/pyparty.git at e719a2c21d0e9ee32d36347792572bd61571de21#egg=pyparty-master > pyproj==1.9.3 > pysdmx==0.1 > pystache==0.5.4 > python-dateutil==2.2.0 > pytz==2013b > -e git+ > https://github.com/hugadams/pyuvvis.git at a40befc64b0ac8a18d344d0e40b32b2b68dc3128#egg=pyuvvis-master > pyzmq==14.3.1 > readline==6.2.4.1 > redis==2.10.3 > requests==2.2.1 > restview==2.0.5 > runipy==0.1.0 > scikit-learn==0.14.1 > scikits.image==0.9.3 > scipy==0.14.0 > shiboken==1.2.1 > six==1.7.3 > ssl-match-hostname==3.4.0.2 > statsmodels==0.5.0 > supplement==0.5dev.dev202 > svgwrite==1.1.2 > sympy==0.7.5 > tornado==4.0.2 > traits==4.5.0 > traitsui==4.4.0 > websocket==0.2.1 > wsgiref==0.1.2 > wxPython==2.8.10.1 > xray==0.1.1 > zeromq==4.0.4 > zlib==1.2.6 > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From hughesadam87 at gmail.com Tue Sep 16 14:02:16 2014 From: hughesadam87 at gmail.com (Adam Hughes) Date: Tue, 16 Sep 2014 14:02:16 -0400 Subject: [IPython-dev] Possible issues with submodule updates In-Reply-To: References: Message-ID: # On branch 2.x # Your branch is up-to-date with 'origin/2.x'. # # Untracked files: # (use "git add ..." to include in what will be committed) # # Untitled0.ipynb # Untitled1.ipynb # Untitled2.ipynb # Untitled3.ipynb # nothing added to commit but untracked files present (use "git add" to track) glue at glue-desktop:~/ipython$ git submodule status 47ed6b9e18670a0d653d99e97e6165c14dd14047 IPython/html/static/components (2.1.0) glue at glue-desktop:~/ipython$ On Tue, Sep 16, 2014 at 1:55 PM, MinRK wrote: > What do you get from git status and git submodule status? > ? > > On Tue, Sep 16, 2014 at 10:43 AM, Adam Hughes > wrote: > >> Hi, >> >> I just updated to the new dev version, and ran python setup.py submodule >> as usual, then setup.py install. When I open a notebook, either new or >> pre-made, I get a blank window. I get this error: >> >> WARNING:tornado.access:404 GET /static/jqueryui.js (127.0.0.1) 0.72ms >> referer=http://localhost:8890/notebooks/Untitled0.ipynb >> >> I've updated tornado, and nothing happens. I've reverted back to ipython >> 2.3 and I still get this. I'm on ubuntu. >> >> My friend is using mac osx 10.7. Her notebook actually loadas, but runs >> her first cell, regardless of what's in it, the kernel freezes. IE the >> cell's indicator changes to a " * " and stays like that. >> >> Is anyone else experiences such issues? >> >> Here is my pip freeze output (note pip freeze still says on on ipython >> 3.0, but if I run ipython in the terminal, it starts as 2.3: >> >> Canopy==1.4.0.dev6600 >> Cython==0.21 >> Examples==7.3 >> Flask==0.10.1 >> Jinja2==2.7.3 >> MKL==10.3 >> Markdown==2.4.1 >> MarkupSafe==0.23 >> PIL==1.1.7 >> PySide==1.2.1 >> PyYAML==3.11 >> Pygments==1.6.0 >> PythonDoc==2.7.3 >> Qt==4.8.5 >> Shapely==1.3.2 >> VTK==5.10.1 >> Werkzeug==0.9.6 >> appinst==2.1.2 >> apptools==4.2.1 >> atom==0.3.9 >> backports.ssl-match-hostname==3.4.0.2 >> basemap==1.0.7 >> bokeh==0.5.2 >> casuarius==1.1 >> certifi==14.05.14 >> chaco==4.4.1 >> cloud==2.4.6 >> colorama==0.3.1 >> configobj==5.0.6 >> coverage==3.7.1 >> docutils==0.11 >> enable==4.4.1 >> enaml==0.9.5 >> encore==0.5.1 >> enstaller==4.6.5 >> envisage==4.4.0 >> esky==0.9.8dev >> etsproxy==0.1.2 >> faulthandler==2.2 >> feedparser==5.1.3 >> freetype==2.5.3 >> geopandas==0.1.0.dev-35c2f5b >> gevent==1.0.1 >> gevent-websocket==0.9.3 >> glib==2.36.1 >> gnureadline==6.2.5 >> greenlet==0.4.3 >> grits-client==0.1 >> gst-plugins-bad==0.10.23 >> gst-plugins-base==0.10.36 >> gst-plugins-good==0.10.30 >> gstreamer==0.10.36 >> idle==2.7.3 >> ipython==3.0.0-dev >> itsdangerous==0.24 >> jdcal==1.0 >> jsonpickle==0.4.0 >> jsonpointer==1.4 >> jsonschema==2.3.0 >> kernmagic==0.2.0 >> keyring==3.6dev >> kiwisolver==0.1.2 >> libffi==3.0.13 >> libgfortran==3.0.0 >> libjpeg==7.0 >> libjpeg62==6.2 >> libncurses==5.9 >> libogg==1.3.0 >> libpng==1.6.12 >> libtheora==1.1.1 >> libvpx==1.1.0 >> libxml2==2.7.8 >> matplotlib==1.4.0 >> mayavi==4.3.1 >> mock==1.0.1 >> nbopen==0.1 >> nmrglue==0.4 >> nose==1.3.3 >> numpy==1.8.2 >> openpyxl==2.0.3 >> pandas==0.14.0 >> patsy==0.2.1 >> plotly==1.1.4 >> ply==3.4 >> psutil==1.2.1 >> pyaudio==0.2.4 >> pyface==4.4.0 >> pyflakes==0.7.3 >> pyglet==1.1.4 >> pyparsing==2.0.2 >> -e git+ >> https://github.com/hugadams/pyparty.git at e719a2c21d0e9ee32d36347792572bd61571de21#egg=pyparty-master >> pyproj==1.9.3 >> pysdmx==0.1 >> pystache==0.5.4 >> python-dateutil==2.2.0 >> pytz==2013b >> -e git+ >> https://github.com/hugadams/pyuvvis.git at a40befc64b0ac8a18d344d0e40b32b2b68dc3128#egg=pyuvvis-master >> pyzmq==14.3.1 >> readline==6.2.4.1 >> redis==2.10.3 >> requests==2.2.1 >> restview==2.0.5 >> runipy==0.1.0 >> scikit-learn==0.14.1 >> scikits.image==0.9.3 >> scipy==0.14.0 >> shiboken==1.2.1 >> six==1.7.3 >> ssl-match-hostname==3.4.0.2 >> statsmodels==0.5.0 >> supplement==0.5dev.dev202 >> svgwrite==1.1.2 >> sympy==0.7.5 >> tornado==4.0.2 >> traits==4.5.0 >> traitsui==4.4.0 >> websocket==0.2.1 >> wsgiref==0.1.2 >> wxPython==2.8.10.1 >> xray==0.1.1 >> zeromq==4.0.4 >> zlib==1.2.6 >> >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From nolan.nichols at gmail.com Tue Sep 16 14:00:50 2014 From: nolan.nichols at gmail.com (nicholsn) Date: Tue, 16 Sep 2014 11:00:50 -0700 (PDT) Subject: [IPython-dev] API to Modify Notebook Metadata In-Reply-To: <1410719347782-5071571.post@n6.nabble.com> References: <541510A7.6070306@creativetrax.com> <1410719347782-5071571.post@n6.nabble.com> Message-ID: <1410890450698-5071713.post@n6.nabble.com> nicholsn wrote > How would I go about retrieving a dict of the metadata I just set? Not sure if this is the preferred approach, but just to close the loop. -- from IPython.display import Javascript js = """ var command = "meta = " + JSON.stringify(IPython.notebook.metadata); var kernel = IPython.notebook.kernel; kernel.execute(command); """ Javascript(js) meta -- View this message in context: http://python.6.x6.nabble.com/API-to-Modify-Notebook-Metadata-tp5071535p5071713.html Sent from the IPython - Development mailing list archive at Nabble.com. From hughesadam87 at gmail.com Tue Sep 16 14:09:26 2014 From: hughesadam87 at gmail.com (Adam Hughes) Date: Tue, 16 Sep 2014 14:09:26 -0400 Subject: [IPython-dev] Possible issues with submodule updates In-Reply-To: References: Message-ID: Hey Min, This was some weird browser error. I hadn't thought to reboot my system, but indeed it was something with my system. Sorry for being too dense to think to try this first! On Tue, Sep 16, 2014 at 2:02 PM, Adam Hughes wrote: > # On branch 2.x > # Your branch is up-to-date with 'origin/2.x'. > # > # Untracked files: > # (use "git add ..." to include in what will be committed) > # > # Untitled0.ipynb > # Untitled1.ipynb > # Untitled2.ipynb > # Untitled3.ipynb > # > nothing added to commit but untracked files present (use "git add" to > track) > glue at glue-desktop:~/ipython$ git submodule status > 47ed6b9e18670a0d653d99e97e6165c14dd14047 IPython/html/static/components > (2.1.0) > glue at glue-desktop:~/ipython$ > > > On Tue, Sep 16, 2014 at 1:55 PM, MinRK wrote: > >> What do you get from git status and git submodule status? >> ? >> >> On Tue, Sep 16, 2014 at 10:43 AM, Adam Hughes >> wrote: >> >>> Hi, >>> >>> I just updated to the new dev version, and ran python setup.py submodule >>> as usual, then setup.py install. When I open a notebook, either new or >>> pre-made, I get a blank window. I get this error: >>> >>> WARNING:tornado.access:404 GET /static/jqueryui.js (127.0.0.1) 0.72ms >>> referer=http://localhost:8890/notebooks/Untitled0.ipynb >>> >>> I've updated tornado, and nothing happens. I've reverted back to >>> ipython 2.3 and I still get this. I'm on ubuntu. >>> >>> My friend is using mac osx 10.7. Her notebook actually loadas, but runs >>> her first cell, regardless of what's in it, the kernel freezes. IE the >>> cell's indicator changes to a " * " and stays like that. >>> >>> Is anyone else experiences such issues? >>> >>> Here is my pip freeze output (note pip freeze still says on on ipython >>> 3.0, but if I run ipython in the terminal, it starts as 2.3: >>> >>> Canopy==1.4.0.dev6600 >>> Cython==0.21 >>> Examples==7.3 >>> Flask==0.10.1 >>> Jinja2==2.7.3 >>> MKL==10.3 >>> Markdown==2.4.1 >>> MarkupSafe==0.23 >>> PIL==1.1.7 >>> PySide==1.2.1 >>> PyYAML==3.11 >>> Pygments==1.6.0 >>> PythonDoc==2.7.3 >>> Qt==4.8.5 >>> Shapely==1.3.2 >>> VTK==5.10.1 >>> Werkzeug==0.9.6 >>> appinst==2.1.2 >>> apptools==4.2.1 >>> atom==0.3.9 >>> backports.ssl-match-hostname==3.4.0.2 >>> basemap==1.0.7 >>> bokeh==0.5.2 >>> casuarius==1.1 >>> certifi==14.05.14 >>> chaco==4.4.1 >>> cloud==2.4.6 >>> colorama==0.3.1 >>> configobj==5.0.6 >>> coverage==3.7.1 >>> docutils==0.11 >>> enable==4.4.1 >>> enaml==0.9.5 >>> encore==0.5.1 >>> enstaller==4.6.5 >>> envisage==4.4.0 >>> esky==0.9.8dev >>> etsproxy==0.1.2 >>> faulthandler==2.2 >>> feedparser==5.1.3 >>> freetype==2.5.3 >>> geopandas==0.1.0.dev-35c2f5b >>> gevent==1.0.1 >>> gevent-websocket==0.9.3 >>> glib==2.36.1 >>> gnureadline==6.2.5 >>> greenlet==0.4.3 >>> grits-client==0.1 >>> gst-plugins-bad==0.10.23 >>> gst-plugins-base==0.10.36 >>> gst-plugins-good==0.10.30 >>> gstreamer==0.10.36 >>> idle==2.7.3 >>> ipython==3.0.0-dev >>> itsdangerous==0.24 >>> jdcal==1.0 >>> jsonpickle==0.4.0 >>> jsonpointer==1.4 >>> jsonschema==2.3.0 >>> kernmagic==0.2.0 >>> keyring==3.6dev >>> kiwisolver==0.1.2 >>> libffi==3.0.13 >>> libgfortran==3.0.0 >>> libjpeg==7.0 >>> libjpeg62==6.2 >>> libncurses==5.9 >>> libogg==1.3.0 >>> libpng==1.6.12 >>> libtheora==1.1.1 >>> libvpx==1.1.0 >>> libxml2==2.7.8 >>> matplotlib==1.4.0 >>> mayavi==4.3.1 >>> mock==1.0.1 >>> nbopen==0.1 >>> nmrglue==0.4 >>> nose==1.3.3 >>> numpy==1.8.2 >>> openpyxl==2.0.3 >>> pandas==0.14.0 >>> patsy==0.2.1 >>> plotly==1.1.4 >>> ply==3.4 >>> psutil==1.2.1 >>> pyaudio==0.2.4 >>> pyface==4.4.0 >>> pyflakes==0.7.3 >>> pyglet==1.1.4 >>> pyparsing==2.0.2 >>> -e git+ >>> https://github.com/hugadams/pyparty.git at e719a2c21d0e9ee32d36347792572bd61571de21#egg=pyparty-master >>> pyproj==1.9.3 >>> pysdmx==0.1 >>> pystache==0.5.4 >>> python-dateutil==2.2.0 >>> pytz==2013b >>> -e git+ >>> https://github.com/hugadams/pyuvvis.git at a40befc64b0ac8a18d344d0e40b32b2b68dc3128#egg=pyuvvis-master >>> pyzmq==14.3.1 >>> readline==6.2.4.1 >>> redis==2.10.3 >>> requests==2.2.1 >>> restview==2.0.5 >>> runipy==0.1.0 >>> scikit-learn==0.14.1 >>> scikits.image==0.9.3 >>> scipy==0.14.0 >>> shiboken==1.2.1 >>> six==1.7.3 >>> ssl-match-hostname==3.4.0.2 >>> statsmodels==0.5.0 >>> supplement==0.5dev.dev202 >>> svgwrite==1.1.2 >>> sympy==0.7.5 >>> tornado==4.0.2 >>> traits==4.5.0 >>> traitsui==4.4.0 >>> websocket==0.2.1 >>> wsgiref==0.1.2 >>> wxPython==2.8.10.1 >>> xray==0.1.1 >>> zeromq==4.0.4 >>> zlib==1.2.6 >>> >>> >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ndbecker2 at gmail.com Tue Sep 16 14:16:55 2014 From: ndbecker2 at gmail.com (Neal Becker) Date: Tue, 16 Sep 2014 14:16:55 -0400 Subject: [IPython-dev] KaTeX (alternative to mathjax?) Message-ID: http://khan.github.io/KaTeX/ -- -- Those who don't understand recursion are doomed to repeat it From andrew.gibiansky at gmail.com Tue Sep 16 14:21:55 2014 From: andrew.gibiansky at gmail.com (Andrew Gibiansky) Date: Tue, 16 Sep 2014 11:21:55 -0700 Subject: [IPython-dev] KaTeX (alternative to mathjax?) In-Reply-To: References: Message-ID: I have some questions that are not answered well on that page: - Is the only advantage over MathJax speed? If so, the fact that IPython notebooks are typically used in cells reduces the usefulness somewhat, as I usually only need to revaluate smallish cells. (Of course, maybe using this for nbconvert output would be useful....) - Does it render all of the same code as MathJax would? e.g. do things like \begin{align*} ... \end{align*} still work? - Are there things that KaTeX does that MathJax does *not*, besides speed? I think these questions would be important to answer before using it. -- Andrew On Tue, Sep 16, 2014 at 11:16 AM, Neal Becker wrote: > http://khan.github.io/KaTeX/ > > -- > -- Those who don't understand recursion are doomed to repeat it > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: From andrew.gibiansky at gmail.com Tue Sep 16 14:21:55 2014 From: andrew.gibiansky at gmail.com (Andrew Gibiansky) Date: Tue, 16 Sep 2014 11:21:55 -0700 Subject: [IPython-dev] KaTeX (alternative to mathjax?) In-Reply-To: References: Message-ID: I have some questions that are not answered well on that page: - Is the only advantage over MathJax speed? If so, the fact that IPython notebooks are typically used in cells reduces the usefulness somewhat, as I usually only need to revaluate smallish cells. (Of course, maybe using this for nbconvert output would be useful....) - Does it render all of the same code as MathJax would? e.g. do things like \begin{align*} ... \end{align*} still work? - Are there things that KaTeX does that MathJax does *not*, besides speed? I think these questions would be important to answer before using it. -- Andrew On Tue, Sep 16, 2014 at 11:16 AM, Neal Becker wrote: > http://khan.github.io/KaTeX/ > > -- > -- Those who don't understand recursion are doomed to repeat it > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: From hughesadam87 at gmail.com Tue Sep 16 14:27:54 2014 From: hughesadam87 at gmail.com (Adam Hughes) Date: Tue, 16 Sep 2014 14:27:54 -0400 Subject: [IPython-dev] Widget example that uses classes instead of globals? In-Reply-To: References: <-1189340719239998470@unknownmsgid> Message-ID: Nicholas, This is an amazing example. Thanks so much for helping us this much! Will send you some updates when we are able to get it running with our data and credit you in this. Is there a special way you'd like to be acknowledged or cited? On Mon, Sep 15, 2014 at 11:19 PM, Nicholas Bollweg wrote: > @antonino: I hadn't thought to use interact that way! __call__ might be > too magic to be used that way... but you can create a non-bound function > (not a method, though self would be in scope!) in the constructor of a > widget that will respond to interact: > > from IPython.html.widgets import interact, ContainerWidget, HTMLWidget >> >> class Carousel(ContainerWidget): >> def __init__(self, *args, **kwargs): >> self.might_show = [HTMLWidget(value="

%s

" % i) for i in >> range(10)] >> super(Carousel, self).__init__(*args, **kwargs) >> >> def interact(n): >> self.children = [self.might_show[n]] >> >> self.show = show >> >> carousel = Carousel() >> interact(carousel.interact, n=(0, len(carousel.might_show)-1)) >> carousel >> > > I don't know much about how matplotlib interacts with widgets/traitlets... > but presumably the ImageWidget will accept them as its value. > > You could move even more behavior into the class itself, but eventually > one would likely need something more complicated than what interact > provides out of the box... > > @adam: Sorry it took me a while to respond. Here is an updated version of > the fake GUI, implemented as a series of classes: a standalone graph, a > couple reusable control components and the full-blown end user GUI. I tried > to put a few examples of different techniques in that we have used: link, > on_trait_changed, CSS, Bootstrap. I didn't do any custom Backbone, as that > is a whole other kettle of fish. > > >> >> http://nbviewer.ipython.org/gist/bollwyvl/ddd4bf5d7c879012fa2c >> > > There are a few more gotchas that would come along with this, such as > installing assets, if you end up using them, but there are a good number of > threads/examples out there for install_nbextension/load_nbextensions. In a > pinch, you could even cheat and have an HTML embed the style directly, I > guess! > > I didn't use the "wire" concept from before: while it has proven useful > for quickly hacking stuff together, i have found it might be a bit "cute" > for something that one actually wanted to release and/or expect people to > be able to extend. If i can figure out how to get it to easily un-listen > for things, it might be work saving, but in the meantime link and > on_trait_changed are good enough! > > Hope this helps! > > On Sat, Aug 30, 2014 at 2:21 PM, Antonino Ingargiola > wrote: > >> Hi, >> >> Sorry for entering in the discussion on-fly... >> >> My question is more specific (but possibly very similar). Would be >> possible to call interact with a class object (i.e. a callable class) >> instead of a function? This would allow to store all the GUI specific state >> in the class (for example precomputing figures) without the need of using >> globals. >> >> When I quickly tried (with ipython 2.2), interact returned an error >> complaining about the number of parameters passed to the object. So I >> resorted to using globals. Below I attached the code I currently use to >> pre-compute a set of figures (a slider selects which figure to display). I >> would appreciate any comment on possibly improving this pattern. >> >> fig_cache = {} >> def plot_mfit_i(ich=0, nodisplay=False): >> global fig_cache >> if ich not in fig_cache: >> fig = mfit.plot_mfit(fitter, ich=ich, residuals=True, >> return_fig=True) >> fig_cache[ich] = fig >> plt.close(fig) >> if not nodisplay: >> display(fig_cache[ich]) >> >> for i in range(8): plot_mfit_i(i, nodisplay=True) # Precompute all the >> figures >> >> interact(plot_mfit_i, ich=(0, 7), nodisplay=fixed(False)); # display the >> figure selected through the slider >> >> -- >> Antonio >> >> On Sat, Aug 30, 2014 at 10:49 AM, Cyrille Rossant < >> cyrille.rossant at gmail.com> wrote: >> >>> I think you can use the "display" function to render a widget instance, >>> does that answer your question? >>> ------------------------------ >>> De : Adam Hughes >>> Envoy? : ?30/?08/?2014 18:43 >>> ? : IPython developers list >>> Objet : Re: [IPython-dev] Widget example that uses classes instead of >>> globals? >>> >>> And just to clarify, I presume that the notebook is actively "looking" >>> for particular functions or something in the cell that let's the notebook >>> know "hey, this is widget/GUI code, I need to output it as so". I had >>> worried that if this critical piece was buried in a class, the notebook >>> wouldn't recognize it, and the GUI wouldn't display. >>> >>> >>> On Sat, Aug 30, 2014 at 1:41 PM, Adam Hughes >>> wrote: >>> >>>> Hi, >>>> >>>> This question follows directly from this recent thread on the >>>> feasiblity of widgets ( >>>> http://python.6.x6.nabble.com/Feasilibity-of-widgets-layout-for-mimicking-this-td5068197.html) >>>> but I thought was specific enough to be a new thread. >>>> >>>> In all of the notebook examples I've seen, a GUI is defined in its own >>>> cell with global variables that are shared between functions. I'd really >>>> like to see a complete, simple example of a GUI build as a class, where >>>> most of the events, updates and default values are set within the class. >>>> And then when the class is instantiated, the notebook somehow can still >>>> output the GUI. >>>> >>>> For example, would something of this design be compatible with the >>>> current widget design pattern: >>>> >>>> *class Foo(object):* >>>> >>>> * variable = defaultvalue* >>>> >>>> * def update_variable(self):* >>>> * ....* >>>> >>>> * def redraw(self):* >>>> * ...* >>>> >>>> *# Instantiate the class* >>>> *f = Foo()* >>>> *f.variable_widget.on_trait_change(update_variable, 'value')* >>>> >>>> Or is this type of design pattern out of the question? We're trying to >>>> move in this direction so that we can compartmentalize and template as much >>>> behavior as possible, and make a simple framework for building up more >>>> complex GUIs. It's just now clear to me if such a pattern is possible. If >>>> anyone has any insights or examples, would you mind sharing? >>>> >>>> THanks >>>> >>> >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From hughesadam87 at gmail.com Tue Sep 16 14:28:49 2014 From: hughesadam87 at gmail.com (Adam Hughes) Date: Tue, 16 Sep 2014 14:28:49 -0400 Subject: [IPython-dev] Possible issues with submodule updates In-Reply-To: References: Message-ID: Just a quick update. I was able to get 3.0.0 working. Interestingly, when I update from 2-->3, my chrome browser gets hung up. That's what happened originally, so it is the installation that does something to the browser. Restarting the computer gets rid of it. Not sure if this is just a chrome issue. Thanks On Tue, Sep 16, 2014 at 2:09 PM, Adam Hughes wrote: > Hey Min, > > This was some weird browser error. I hadn't thought to reboot my system, > but indeed it was something with my system. Sorry for being too dense to > think to try this first! > > On Tue, Sep 16, 2014 at 2:02 PM, Adam Hughes > wrote: > >> # On branch 2.x >> # Your branch is up-to-date with 'origin/2.x'. >> # >> # Untracked files: >> # (use "git add ..." to include in what will be committed) >> # >> # Untitled0.ipynb >> # Untitled1.ipynb >> # Untitled2.ipynb >> # Untitled3.ipynb >> # >> nothing added to commit but untracked files present (use "git add" to >> track) >> glue at glue-desktop:~/ipython$ git submodule status >> 47ed6b9e18670a0d653d99e97e6165c14dd14047 IPython/html/static/components >> (2.1.0) >> glue at glue-desktop:~/ipython$ >> >> >> On Tue, Sep 16, 2014 at 1:55 PM, MinRK wrote: >> >>> What do you get from git status and git submodule status? >>> ? >>> >>> On Tue, Sep 16, 2014 at 10:43 AM, Adam Hughes >>> wrote: >>> >>>> Hi, >>>> >>>> I just updated to the new dev version, and ran python setup.py >>>> submodule as usual, then setup.py install. When I open a notebook, either >>>> new or pre-made, I get a blank window. I get this error: >>>> >>>> WARNING:tornado.access:404 GET /static/jqueryui.js (127.0.0.1) 0.72ms >>>> referer=http://localhost:8890/notebooks/Untitled0.ipynb >>>> >>>> I've updated tornado, and nothing happens. I've reverted back to >>>> ipython 2.3 and I still get this. I'm on ubuntu. >>>> >>>> My friend is using mac osx 10.7. Her notebook actually loadas, but >>>> runs her first cell, regardless of what's in it, the kernel freezes. IE >>>> the cell's indicator changes to a " * " and stays like that. >>>> >>>> Is anyone else experiences such issues? >>>> >>>> Here is my pip freeze output (note pip freeze still says on on ipython >>>> 3.0, but if I run ipython in the terminal, it starts as 2.3: >>>> >>>> Canopy==1.4.0.dev6600 >>>> Cython==0.21 >>>> Examples==7.3 >>>> Flask==0.10.1 >>>> Jinja2==2.7.3 >>>> MKL==10.3 >>>> Markdown==2.4.1 >>>> MarkupSafe==0.23 >>>> PIL==1.1.7 >>>> PySide==1.2.1 >>>> PyYAML==3.11 >>>> Pygments==1.6.0 >>>> PythonDoc==2.7.3 >>>> Qt==4.8.5 >>>> Shapely==1.3.2 >>>> VTK==5.10.1 >>>> Werkzeug==0.9.6 >>>> appinst==2.1.2 >>>> apptools==4.2.1 >>>> atom==0.3.9 >>>> backports.ssl-match-hostname==3.4.0.2 >>>> basemap==1.0.7 >>>> bokeh==0.5.2 >>>> casuarius==1.1 >>>> certifi==14.05.14 >>>> chaco==4.4.1 >>>> cloud==2.4.6 >>>> colorama==0.3.1 >>>> configobj==5.0.6 >>>> coverage==3.7.1 >>>> docutils==0.11 >>>> enable==4.4.1 >>>> enaml==0.9.5 >>>> encore==0.5.1 >>>> enstaller==4.6.5 >>>> envisage==4.4.0 >>>> esky==0.9.8dev >>>> etsproxy==0.1.2 >>>> faulthandler==2.2 >>>> feedparser==5.1.3 >>>> freetype==2.5.3 >>>> geopandas==0.1.0.dev-35c2f5b >>>> gevent==1.0.1 >>>> gevent-websocket==0.9.3 >>>> glib==2.36.1 >>>> gnureadline==6.2.5 >>>> greenlet==0.4.3 >>>> grits-client==0.1 >>>> gst-plugins-bad==0.10.23 >>>> gst-plugins-base==0.10.36 >>>> gst-plugins-good==0.10.30 >>>> gstreamer==0.10.36 >>>> idle==2.7.3 >>>> ipython==3.0.0-dev >>>> itsdangerous==0.24 >>>> jdcal==1.0 >>>> jsonpickle==0.4.0 >>>> jsonpointer==1.4 >>>> jsonschema==2.3.0 >>>> kernmagic==0.2.0 >>>> keyring==3.6dev >>>> kiwisolver==0.1.2 >>>> libffi==3.0.13 >>>> libgfortran==3.0.0 >>>> libjpeg==7.0 >>>> libjpeg62==6.2 >>>> libncurses==5.9 >>>> libogg==1.3.0 >>>> libpng==1.6.12 >>>> libtheora==1.1.1 >>>> libvpx==1.1.0 >>>> libxml2==2.7.8 >>>> matplotlib==1.4.0 >>>> mayavi==4.3.1 >>>> mock==1.0.1 >>>> nbopen==0.1 >>>> nmrglue==0.4 >>>> nose==1.3.3 >>>> numpy==1.8.2 >>>> openpyxl==2.0.3 >>>> pandas==0.14.0 >>>> patsy==0.2.1 >>>> plotly==1.1.4 >>>> ply==3.4 >>>> psutil==1.2.1 >>>> pyaudio==0.2.4 >>>> pyface==4.4.0 >>>> pyflakes==0.7.3 >>>> pyglet==1.1.4 >>>> pyparsing==2.0.2 >>>> -e git+ >>>> https://github.com/hugadams/pyparty.git at e719a2c21d0e9ee32d36347792572bd61571de21#egg=pyparty-master >>>> pyproj==1.9.3 >>>> pysdmx==0.1 >>>> pystache==0.5.4 >>>> python-dateutil==2.2.0 >>>> pytz==2013b >>>> -e git+ >>>> https://github.com/hugadams/pyuvvis.git at a40befc64b0ac8a18d344d0e40b32b2b68dc3128#egg=pyuvvis-master >>>> pyzmq==14.3.1 >>>> readline==6.2.4.1 >>>> redis==2.10.3 >>>> requests==2.2.1 >>>> restview==2.0.5 >>>> runipy==0.1.0 >>>> scikit-learn==0.14.1 >>>> scikits.image==0.9.3 >>>> scipy==0.14.0 >>>> shiboken==1.2.1 >>>> six==1.7.3 >>>> ssl-match-hostname==3.4.0.2 >>>> statsmodels==0.5.0 >>>> supplement==0.5dev.dev202 >>>> svgwrite==1.1.2 >>>> sympy==0.7.5 >>>> tornado==4.0.2 >>>> traits==4.5.0 >>>> traitsui==4.4.0 >>>> websocket==0.2.1 >>>> wsgiref==0.1.2 >>>> wxPython==2.8.10.1 >>>> xray==0.1.1 >>>> zeromq==4.0.4 >>>> zlib==1.2.6 >>>> >>>> >>>> >>>> _______________________________________________ >>>> IPython-dev mailing list >>>> IPython-dev at scipy.org >>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>> >>>> >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From hughesadam87 at gmail.com Tue Sep 16 14:35:40 2014 From: hughesadam87 at gmail.com (Adam Hughes) Date: Tue, 16 Sep 2014 14:35:40 -0400 Subject: [IPython-dev] Possible issues with submodule updates In-Reply-To: References: Message-ID: Also, my student is still having her mac freeze out. We reinstalled on her computer, restarted, checked that the git submodule status was the same, and she's still getting frozen cells each time. On Tue, Sep 16, 2014 at 2:28 PM, Adam Hughes wrote: > Just a quick update. > > I was able to get 3.0.0 working. Interestingly, when I update from 2-->3, > my chrome browser gets hung up. That's what happened originally, so it is > the installation that does something to the browser. Restarting the > computer gets rid of it. Not sure if this is just a chrome issue. > > Thanks > > On Tue, Sep 16, 2014 at 2:09 PM, Adam Hughes > wrote: > >> Hey Min, >> >> This was some weird browser error. I hadn't thought to reboot my system, >> but indeed it was something with my system. Sorry for being too dense to >> think to try this first! >> >> On Tue, Sep 16, 2014 at 2:02 PM, Adam Hughes >> wrote: >> >>> # On branch 2.x >>> # Your branch is up-to-date with 'origin/2.x'. >>> # >>> # Untracked files: >>> # (use "git add ..." to include in what will be committed) >>> # >>> # Untitled0.ipynb >>> # Untitled1.ipynb >>> # Untitled2.ipynb >>> # Untitled3.ipynb >>> # >>> nothing added to commit but untracked files present (use "git add" to >>> track) >>> glue at glue-desktop:~/ipython$ git submodule status >>> 47ed6b9e18670a0d653d99e97e6165c14dd14047 IPython/html/static/components >>> (2.1.0) >>> glue at glue-desktop:~/ipython$ >>> >>> >>> On Tue, Sep 16, 2014 at 1:55 PM, MinRK wrote: >>> >>>> What do you get from git status and git submodule status? >>>> ? >>>> >>>> On Tue, Sep 16, 2014 at 10:43 AM, Adam Hughes >>>> wrote: >>>> >>>>> Hi, >>>>> >>>>> I just updated to the new dev version, and ran python setup.py >>>>> submodule as usual, then setup.py install. When I open a notebook, either >>>>> new or pre-made, I get a blank window. I get this error: >>>>> >>>>> WARNING:tornado.access:404 GET /static/jqueryui.js (127.0.0.1) 0.72ms >>>>> referer=http://localhost:8890/notebooks/Untitled0.ipynb >>>>> >>>>> I've updated tornado, and nothing happens. I've reverted back to >>>>> ipython 2.3 and I still get this. I'm on ubuntu. >>>>> >>>>> My friend is using mac osx 10.7. Her notebook actually loadas, but >>>>> runs her first cell, regardless of what's in it, the kernel freezes. IE >>>>> the cell's indicator changes to a " * " and stays like that. >>>>> >>>>> Is anyone else experiences such issues? >>>>> >>>>> Here is my pip freeze output (note pip freeze still says on on ipython >>>>> 3.0, but if I run ipython in the terminal, it starts as 2.3: >>>>> >>>>> Canopy==1.4.0.dev6600 >>>>> Cython==0.21 >>>>> Examples==7.3 >>>>> Flask==0.10.1 >>>>> Jinja2==2.7.3 >>>>> MKL==10.3 >>>>> Markdown==2.4.1 >>>>> MarkupSafe==0.23 >>>>> PIL==1.1.7 >>>>> PySide==1.2.1 >>>>> PyYAML==3.11 >>>>> Pygments==1.6.0 >>>>> PythonDoc==2.7.3 >>>>> Qt==4.8.5 >>>>> Shapely==1.3.2 >>>>> VTK==5.10.1 >>>>> Werkzeug==0.9.6 >>>>> appinst==2.1.2 >>>>> apptools==4.2.1 >>>>> atom==0.3.9 >>>>> backports.ssl-match-hostname==3.4.0.2 >>>>> basemap==1.0.7 >>>>> bokeh==0.5.2 >>>>> casuarius==1.1 >>>>> certifi==14.05.14 >>>>> chaco==4.4.1 >>>>> cloud==2.4.6 >>>>> colorama==0.3.1 >>>>> configobj==5.0.6 >>>>> coverage==3.7.1 >>>>> docutils==0.11 >>>>> enable==4.4.1 >>>>> enaml==0.9.5 >>>>> encore==0.5.1 >>>>> enstaller==4.6.5 >>>>> envisage==4.4.0 >>>>> esky==0.9.8dev >>>>> etsproxy==0.1.2 >>>>> faulthandler==2.2 >>>>> feedparser==5.1.3 >>>>> freetype==2.5.3 >>>>> geopandas==0.1.0.dev-35c2f5b >>>>> gevent==1.0.1 >>>>> gevent-websocket==0.9.3 >>>>> glib==2.36.1 >>>>> gnureadline==6.2.5 >>>>> greenlet==0.4.3 >>>>> grits-client==0.1 >>>>> gst-plugins-bad==0.10.23 >>>>> gst-plugins-base==0.10.36 >>>>> gst-plugins-good==0.10.30 >>>>> gstreamer==0.10.36 >>>>> idle==2.7.3 >>>>> ipython==3.0.0-dev >>>>> itsdangerous==0.24 >>>>> jdcal==1.0 >>>>> jsonpickle==0.4.0 >>>>> jsonpointer==1.4 >>>>> jsonschema==2.3.0 >>>>> kernmagic==0.2.0 >>>>> keyring==3.6dev >>>>> kiwisolver==0.1.2 >>>>> libffi==3.0.13 >>>>> libgfortran==3.0.0 >>>>> libjpeg==7.0 >>>>> libjpeg62==6.2 >>>>> libncurses==5.9 >>>>> libogg==1.3.0 >>>>> libpng==1.6.12 >>>>> libtheora==1.1.1 >>>>> libvpx==1.1.0 >>>>> libxml2==2.7.8 >>>>> matplotlib==1.4.0 >>>>> mayavi==4.3.1 >>>>> mock==1.0.1 >>>>> nbopen==0.1 >>>>> nmrglue==0.4 >>>>> nose==1.3.3 >>>>> numpy==1.8.2 >>>>> openpyxl==2.0.3 >>>>> pandas==0.14.0 >>>>> patsy==0.2.1 >>>>> plotly==1.1.4 >>>>> ply==3.4 >>>>> psutil==1.2.1 >>>>> pyaudio==0.2.4 >>>>> pyface==4.4.0 >>>>> pyflakes==0.7.3 >>>>> pyglet==1.1.4 >>>>> pyparsing==2.0.2 >>>>> -e git+ >>>>> https://github.com/hugadams/pyparty.git at e719a2c21d0e9ee32d36347792572bd61571de21#egg=pyparty-master >>>>> pyproj==1.9.3 >>>>> pysdmx==0.1 >>>>> pystache==0.5.4 >>>>> python-dateutil==2.2.0 >>>>> pytz==2013b >>>>> -e git+ >>>>> https://github.com/hugadams/pyuvvis.git at a40befc64b0ac8a18d344d0e40b32b2b68dc3128#egg=pyuvvis-master >>>>> pyzmq==14.3.1 >>>>> readline==6.2.4.1 >>>>> redis==2.10.3 >>>>> requests==2.2.1 >>>>> restview==2.0.5 >>>>> runipy==0.1.0 >>>>> scikit-learn==0.14.1 >>>>> scikits.image==0.9.3 >>>>> scipy==0.14.0 >>>>> shiboken==1.2.1 >>>>> six==1.7.3 >>>>> ssl-match-hostname==3.4.0.2 >>>>> statsmodels==0.5.0 >>>>> supplement==0.5dev.dev202 >>>>> svgwrite==1.1.2 >>>>> sympy==0.7.5 >>>>> tornado==4.0.2 >>>>> traits==4.5.0 >>>>> traitsui==4.4.0 >>>>> websocket==0.2.1 >>>>> wsgiref==0.1.2 >>>>> wxPython==2.8.10.1 >>>>> xray==0.1.1 >>>>> zeromq==4.0.4 >>>>> zlib==1.2.6 >>>>> >>>>> >>>>> >>>>> _______________________________________________ >>>>> IPython-dev mailing list >>>>> IPython-dev at scipy.org >>>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>>> >>>>> >>>> >>>> _______________________________________________ >>>> IPython-dev mailing list >>>> IPython-dev at scipy.org >>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>> >>>> >>> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From takowl at gmail.com Tue Sep 16 14:44:09 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Tue, 16 Sep 2014 11:44:09 -0700 Subject: [IPython-dev] Possible issues with submodule updates In-Reply-To: References: Message-ID: We have a lot of issues with browsers caching Javascript files. Min's working on a better solution to this, but in the meantime, try clearing the cache as much as possible. Sometimes starting the browser in private mode seems to get round caching issues. Thomas On 16 September 2014 11:35, Adam Hughes wrote: > Also, my student is still having her mac freeze out. We reinstalled on > her computer, restarted, checked that the git submodule status was the > same, and she's still getting frozen cells each time. > > On Tue, Sep 16, 2014 at 2:28 PM, Adam Hughes > wrote: > >> Just a quick update. >> >> I was able to get 3.0.0 working. Interestingly, when I update from >> 2-->3, my chrome browser gets hung up. That's what happened originally, so >> it is the installation that does something to the browser. Restarting the >> computer gets rid of it. Not sure if this is just a chrome issue. >> >> Thanks >> >> On Tue, Sep 16, 2014 at 2:09 PM, Adam Hughes >> wrote: >> >>> Hey Min, >>> >>> This was some weird browser error. I hadn't thought to reboot my >>> system, but indeed it was something with my system. Sorry for being too >>> dense to think to try this first! >>> >>> On Tue, Sep 16, 2014 at 2:02 PM, Adam Hughes >>> wrote: >>> >>>> # On branch 2.x >>>> # Your branch is up-to-date with 'origin/2.x'. >>>> # >>>> # Untracked files: >>>> # (use "git add ..." to include in what will be committed) >>>> # >>>> # Untitled0.ipynb >>>> # Untitled1.ipynb >>>> # Untitled2.ipynb >>>> # Untitled3.ipynb >>>> # >>>> nothing added to commit but untracked files present (use "git add" to >>>> track) >>>> glue at glue-desktop:~/ipython$ git submodule status >>>> 47ed6b9e18670a0d653d99e97e6165c14dd14047 >>>> IPython/html/static/components (2.1.0) >>>> glue at glue-desktop:~/ipython$ >>>> >>>> >>>> On Tue, Sep 16, 2014 at 1:55 PM, MinRK wrote: >>>> >>>>> What do you get from git status and git submodule status? >>>>> ? >>>>> >>>>> On Tue, Sep 16, 2014 at 10:43 AM, Adam Hughes >>>>> wrote: >>>>> >>>>>> Hi, >>>>>> >>>>>> I just updated to the new dev version, and ran python setup.py >>>>>> submodule as usual, then setup.py install. When I open a notebook, either >>>>>> new or pre-made, I get a blank window. I get this error: >>>>>> >>>>>> WARNING:tornado.access:404 GET /static/jqueryui.js (127.0.0.1) 0.72ms >>>>>> referer=http://localhost:8890/notebooks/Untitled0.ipynb >>>>>> >>>>>> I've updated tornado, and nothing happens. I've reverted back to >>>>>> ipython 2.3 and I still get this. I'm on ubuntu. >>>>>> >>>>>> My friend is using mac osx 10.7. Her notebook actually loadas, but >>>>>> runs her first cell, regardless of what's in it, the kernel freezes. IE >>>>>> the cell's indicator changes to a " * " and stays like that. >>>>>> >>>>>> Is anyone else experiences such issues? >>>>>> >>>>>> Here is my pip freeze output (note pip freeze still says on on >>>>>> ipython 3.0, but if I run ipython in the terminal, it starts as 2.3: >>>>>> >>>>>> Canopy==1.4.0.dev6600 >>>>>> Cython==0.21 >>>>>> Examples==7.3 >>>>>> Flask==0.10.1 >>>>>> Jinja2==2.7.3 >>>>>> MKL==10.3 >>>>>> Markdown==2.4.1 >>>>>> MarkupSafe==0.23 >>>>>> PIL==1.1.7 >>>>>> PySide==1.2.1 >>>>>> PyYAML==3.11 >>>>>> Pygments==1.6.0 >>>>>> PythonDoc==2.7.3 >>>>>> Qt==4.8.5 >>>>>> Shapely==1.3.2 >>>>>> VTK==5.10.1 >>>>>> Werkzeug==0.9.6 >>>>>> appinst==2.1.2 >>>>>> apptools==4.2.1 >>>>>> atom==0.3.9 >>>>>> backports.ssl-match-hostname==3.4.0.2 >>>>>> basemap==1.0.7 >>>>>> bokeh==0.5.2 >>>>>> casuarius==1.1 >>>>>> certifi==14.05.14 >>>>>> chaco==4.4.1 >>>>>> cloud==2.4.6 >>>>>> colorama==0.3.1 >>>>>> configobj==5.0.6 >>>>>> coverage==3.7.1 >>>>>> docutils==0.11 >>>>>> enable==4.4.1 >>>>>> enaml==0.9.5 >>>>>> encore==0.5.1 >>>>>> enstaller==4.6.5 >>>>>> envisage==4.4.0 >>>>>> esky==0.9.8dev >>>>>> etsproxy==0.1.2 >>>>>> faulthandler==2.2 >>>>>> feedparser==5.1.3 >>>>>> freetype==2.5.3 >>>>>> geopandas==0.1.0.dev-35c2f5b >>>>>> gevent==1.0.1 >>>>>> gevent-websocket==0.9.3 >>>>>> glib==2.36.1 >>>>>> gnureadline==6.2.5 >>>>>> greenlet==0.4.3 >>>>>> grits-client==0.1 >>>>>> gst-plugins-bad==0.10.23 >>>>>> gst-plugins-base==0.10.36 >>>>>> gst-plugins-good==0.10.30 >>>>>> gstreamer==0.10.36 >>>>>> idle==2.7.3 >>>>>> ipython==3.0.0-dev >>>>>> itsdangerous==0.24 >>>>>> jdcal==1.0 >>>>>> jsonpickle==0.4.0 >>>>>> jsonpointer==1.4 >>>>>> jsonschema==2.3.0 >>>>>> kernmagic==0.2.0 >>>>>> keyring==3.6dev >>>>>> kiwisolver==0.1.2 >>>>>> libffi==3.0.13 >>>>>> libgfortran==3.0.0 >>>>>> libjpeg==7.0 >>>>>> libjpeg62==6.2 >>>>>> libncurses==5.9 >>>>>> libogg==1.3.0 >>>>>> libpng==1.6.12 >>>>>> libtheora==1.1.1 >>>>>> libvpx==1.1.0 >>>>>> libxml2==2.7.8 >>>>>> matplotlib==1.4.0 >>>>>> mayavi==4.3.1 >>>>>> mock==1.0.1 >>>>>> nbopen==0.1 >>>>>> nmrglue==0.4 >>>>>> nose==1.3.3 >>>>>> numpy==1.8.2 >>>>>> openpyxl==2.0.3 >>>>>> pandas==0.14.0 >>>>>> patsy==0.2.1 >>>>>> plotly==1.1.4 >>>>>> ply==3.4 >>>>>> psutil==1.2.1 >>>>>> pyaudio==0.2.4 >>>>>> pyface==4.4.0 >>>>>> pyflakes==0.7.3 >>>>>> pyglet==1.1.4 >>>>>> pyparsing==2.0.2 >>>>>> -e git+ >>>>>> https://github.com/hugadams/pyparty.git at e719a2c21d0e9ee32d36347792572bd61571de21#egg=pyparty-master >>>>>> pyproj==1.9.3 >>>>>> pysdmx==0.1 >>>>>> pystache==0.5.4 >>>>>> python-dateutil==2.2.0 >>>>>> pytz==2013b >>>>>> -e git+ >>>>>> https://github.com/hugadams/pyuvvis.git at a40befc64b0ac8a18d344d0e40b32b2b68dc3128#egg=pyuvvis-master >>>>>> pyzmq==14.3.1 >>>>>> readline==6.2.4.1 >>>>>> redis==2.10.3 >>>>>> requests==2.2.1 >>>>>> restview==2.0.5 >>>>>> runipy==0.1.0 >>>>>> scikit-learn==0.14.1 >>>>>> scikits.image==0.9.3 >>>>>> scipy==0.14.0 >>>>>> shiboken==1.2.1 >>>>>> six==1.7.3 >>>>>> ssl-match-hostname==3.4.0.2 >>>>>> statsmodels==0.5.0 >>>>>> supplement==0.5dev.dev202 >>>>>> svgwrite==1.1.2 >>>>>> sympy==0.7.5 >>>>>> tornado==4.0.2 >>>>>> traits==4.5.0 >>>>>> traitsui==4.4.0 >>>>>> websocket==0.2.1 >>>>>> wsgiref==0.1.2 >>>>>> wxPython==2.8.10.1 >>>>>> xray==0.1.1 >>>>>> zeromq==4.0.4 >>>>>> zlib==1.2.6 >>>>>> >>>>>> >>>>>> >>>>>> _______________________________________________ >>>>>> IPython-dev mailing list >>>>>> IPython-dev at scipy.org >>>>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>>>> >>>>>> >>>>> >>>>> _______________________________________________ >>>>> IPython-dev mailing list >>>>> IPython-dev at scipy.org >>>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>>> >>>>> >>>> >>> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From fperez.net at gmail.com Tue Sep 16 14:47:38 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Tue, 16 Sep 2014 11:47:38 -0700 Subject: [IPython-dev] Possible issues with submodule updates In-Reply-To: References: Message-ID: also, super useful (for Chrome users): https://chrome.google.com/webstore/detail/clear-cache/cppjkneekbjaeellbfkmgnhonkkjfpdn?hl=en On Tue, Sep 16, 2014 at 11:44 AM, Thomas Kluyver wrote: > We have a lot of issues with browsers caching Javascript files. Min's > working on a better solution to this, but in the meantime, try clearing the > cache as much as possible. Sometimes starting the browser in private mode > seems to get round caching issues. > > Thomas > > On 16 September 2014 11:35, Adam Hughes wrote: > >> Also, my student is still having her mac freeze out. We reinstalled on >> her computer, restarted, checked that the git submodule status was the >> same, and she's still getting frozen cells each time. >> >> On Tue, Sep 16, 2014 at 2:28 PM, Adam Hughes >> wrote: >> >>> Just a quick update. >>> >>> I was able to get 3.0.0 working. Interestingly, when I update from >>> 2-->3, my chrome browser gets hung up. That's what happened originally, so >>> it is the installation that does something to the browser. Restarting the >>> computer gets rid of it. Not sure if this is just a chrome issue. >>> >>> Thanks >>> >>> On Tue, Sep 16, 2014 at 2:09 PM, Adam Hughes >>> wrote: >>> >>>> Hey Min, >>>> >>>> This was some weird browser error. I hadn't thought to reboot my >>>> system, but indeed it was something with my system. Sorry for being too >>>> dense to think to try this first! >>>> >>>> On Tue, Sep 16, 2014 at 2:02 PM, Adam Hughes >>>> wrote: >>>> >>>>> # On branch 2.x >>>>> # Your branch is up-to-date with 'origin/2.x'. >>>>> # >>>>> # Untracked files: >>>>> # (use "git add ..." to include in what will be committed) >>>>> # >>>>> # Untitled0.ipynb >>>>> # Untitled1.ipynb >>>>> # Untitled2.ipynb >>>>> # Untitled3.ipynb >>>>> # >>>>> nothing added to commit but untracked files present (use "git add" to >>>>> track) >>>>> glue at glue-desktop:~/ipython$ git submodule status >>>>> 47ed6b9e18670a0d653d99e97e6165c14dd14047 >>>>> IPython/html/static/components (2.1.0) >>>>> glue at glue-desktop:~/ipython$ >>>>> >>>>> >>>>> On Tue, Sep 16, 2014 at 1:55 PM, MinRK wrote: >>>>> >>>>>> What do you get from git status and git submodule status? >>>>>> ? >>>>>> >>>>>> On Tue, Sep 16, 2014 at 10:43 AM, Adam Hughes >>>>> > wrote: >>>>>> >>>>>>> Hi, >>>>>>> >>>>>>> I just updated to the new dev version, and ran python setup.py >>>>>>> submodule as usual, then setup.py install. When I open a notebook, either >>>>>>> new or pre-made, I get a blank window. I get this error: >>>>>>> >>>>>>> WARNING:tornado.access:404 GET /static/jqueryui.js (127.0.0.1) >>>>>>> 0.72ms referer=http://localhost:8890/notebooks/Untitled0.ipynb >>>>>>> >>>>>>> I've updated tornado, and nothing happens. I've reverted back to >>>>>>> ipython 2.3 and I still get this. I'm on ubuntu. >>>>>>> >>>>>>> My friend is using mac osx 10.7. Her notebook actually loadas, but >>>>>>> runs her first cell, regardless of what's in it, the kernel freezes. IE >>>>>>> the cell's indicator changes to a " * " and stays like that. >>>>>>> >>>>>>> Is anyone else experiences such issues? >>>>>>> >>>>>>> Here is my pip freeze output (note pip freeze still says on on >>>>>>> ipython 3.0, but if I run ipython in the terminal, it starts as 2.3: >>>>>>> >>>>>>> Canopy==1.4.0.dev6600 >>>>>>> Cython==0.21 >>>>>>> Examples==7.3 >>>>>>> Flask==0.10.1 >>>>>>> Jinja2==2.7.3 >>>>>>> MKL==10.3 >>>>>>> Markdown==2.4.1 >>>>>>> MarkupSafe==0.23 >>>>>>> PIL==1.1.7 >>>>>>> PySide==1.2.1 >>>>>>> PyYAML==3.11 >>>>>>> Pygments==1.6.0 >>>>>>> PythonDoc==2.7.3 >>>>>>> Qt==4.8.5 >>>>>>> Shapely==1.3.2 >>>>>>> VTK==5.10.1 >>>>>>> Werkzeug==0.9.6 >>>>>>> appinst==2.1.2 >>>>>>> apptools==4.2.1 >>>>>>> atom==0.3.9 >>>>>>> backports.ssl-match-hostname==3.4.0.2 >>>>>>> basemap==1.0.7 >>>>>>> bokeh==0.5.2 >>>>>>> casuarius==1.1 >>>>>>> certifi==14.05.14 >>>>>>> chaco==4.4.1 >>>>>>> cloud==2.4.6 >>>>>>> colorama==0.3.1 >>>>>>> configobj==5.0.6 >>>>>>> coverage==3.7.1 >>>>>>> docutils==0.11 >>>>>>> enable==4.4.1 >>>>>>> enaml==0.9.5 >>>>>>> encore==0.5.1 >>>>>>> enstaller==4.6.5 >>>>>>> envisage==4.4.0 >>>>>>> esky==0.9.8dev >>>>>>> etsproxy==0.1.2 >>>>>>> faulthandler==2.2 >>>>>>> feedparser==5.1.3 >>>>>>> freetype==2.5.3 >>>>>>> geopandas==0.1.0.dev-35c2f5b >>>>>>> gevent==1.0.1 >>>>>>> gevent-websocket==0.9.3 >>>>>>> glib==2.36.1 >>>>>>> gnureadline==6.2.5 >>>>>>> greenlet==0.4.3 >>>>>>> grits-client==0.1 >>>>>>> gst-plugins-bad==0.10.23 >>>>>>> gst-plugins-base==0.10.36 >>>>>>> gst-plugins-good==0.10.30 >>>>>>> gstreamer==0.10.36 >>>>>>> idle==2.7.3 >>>>>>> ipython==3.0.0-dev >>>>>>> itsdangerous==0.24 >>>>>>> jdcal==1.0 >>>>>>> jsonpickle==0.4.0 >>>>>>> jsonpointer==1.4 >>>>>>> jsonschema==2.3.0 >>>>>>> kernmagic==0.2.0 >>>>>>> keyring==3.6dev >>>>>>> kiwisolver==0.1.2 >>>>>>> libffi==3.0.13 >>>>>>> libgfortran==3.0.0 >>>>>>> libjpeg==7.0 >>>>>>> libjpeg62==6.2 >>>>>>> libncurses==5.9 >>>>>>> libogg==1.3.0 >>>>>>> libpng==1.6.12 >>>>>>> libtheora==1.1.1 >>>>>>> libvpx==1.1.0 >>>>>>> libxml2==2.7.8 >>>>>>> matplotlib==1.4.0 >>>>>>> mayavi==4.3.1 >>>>>>> mock==1.0.1 >>>>>>> nbopen==0.1 >>>>>>> nmrglue==0.4 >>>>>>> nose==1.3.3 >>>>>>> numpy==1.8.2 >>>>>>> openpyxl==2.0.3 >>>>>>> pandas==0.14.0 >>>>>>> patsy==0.2.1 >>>>>>> plotly==1.1.4 >>>>>>> ply==3.4 >>>>>>> psutil==1.2.1 >>>>>>> pyaudio==0.2.4 >>>>>>> pyface==4.4.0 >>>>>>> pyflakes==0.7.3 >>>>>>> pyglet==1.1.4 >>>>>>> pyparsing==2.0.2 >>>>>>> -e git+ >>>>>>> https://github.com/hugadams/pyparty.git at e719a2c21d0e9ee32d36347792572bd61571de21#egg=pyparty-master >>>>>>> pyproj==1.9.3 >>>>>>> pysdmx==0.1 >>>>>>> pystache==0.5.4 >>>>>>> python-dateutil==2.2.0 >>>>>>> pytz==2013b >>>>>>> -e git+ >>>>>>> https://github.com/hugadams/pyuvvis.git at a40befc64b0ac8a18d344d0e40b32b2b68dc3128#egg=pyuvvis-master >>>>>>> pyzmq==14.3.1 >>>>>>> readline==6.2.4.1 >>>>>>> redis==2.10.3 >>>>>>> requests==2.2.1 >>>>>>> restview==2.0.5 >>>>>>> runipy==0.1.0 >>>>>>> scikit-learn==0.14.1 >>>>>>> scikits.image==0.9.3 >>>>>>> scipy==0.14.0 >>>>>>> shiboken==1.2.1 >>>>>>> six==1.7.3 >>>>>>> ssl-match-hostname==3.4.0.2 >>>>>>> statsmodels==0.5.0 >>>>>>> supplement==0.5dev.dev202 >>>>>>> svgwrite==1.1.2 >>>>>>> sympy==0.7.5 >>>>>>> tornado==4.0.2 >>>>>>> traits==4.5.0 >>>>>>> traitsui==4.4.0 >>>>>>> websocket==0.2.1 >>>>>>> wsgiref==0.1.2 >>>>>>> wxPython==2.8.10.1 >>>>>>> xray==0.1.1 >>>>>>> zeromq==4.0.4 >>>>>>> zlib==1.2.6 >>>>>>> >>>>>>> >>>>>>> >>>>>>> _______________________________________________ >>>>>>> IPython-dev mailing list >>>>>>> IPython-dev at scipy.org >>>>>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>>>>> >>>>>>> >>>>>> >>>>>> _______________________________________________ >>>>>> IPython-dev mailing list >>>>>> IPython-dev at scipy.org >>>>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>>>> >>>>>> >>>>> >>>> >>> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: From hughesadam87 at gmail.com Tue Sep 16 14:58:22 2014 From: hughesadam87 at gmail.com (Adam Hughes) Date: Tue, 16 Sep 2014 14:58:22 -0400 Subject: [IPython-dev] Possible issues with submodule updates In-Reply-To: References: Message-ID: Ok thanks for the help. So you guys haven't had any issues installing this onto mac and running on chome I take it? Still odd that my colleague is getting hung up. On Tue, Sep 16, 2014 at 2:47 PM, Fernando Perez wrote: > also, super useful (for Chrome users): > https://chrome.google.com/webstore/detail/clear-cache/cppjkneekbjaeellbfkmgnhonkkjfpdn?hl=en > > On Tue, Sep 16, 2014 at 11:44 AM, Thomas Kluyver wrote: > >> We have a lot of issues with browsers caching Javascript files. Min's >> working on a better solution to this, but in the meantime, try clearing the >> cache as much as possible. Sometimes starting the browser in private mode >> seems to get round caching issues. >> >> Thomas >> >> On 16 September 2014 11:35, Adam Hughes wrote: >> >>> Also, my student is still having her mac freeze out. We reinstalled on >>> her computer, restarted, checked that the git submodule status was the >>> same, and she's still getting frozen cells each time. >>> >>> On Tue, Sep 16, 2014 at 2:28 PM, Adam Hughes >>> wrote: >>> >>>> Just a quick update. >>>> >>>> I was able to get 3.0.0 working. Interestingly, when I update from >>>> 2-->3, my chrome browser gets hung up. That's what happened originally, so >>>> it is the installation that does something to the browser. Restarting the >>>> computer gets rid of it. Not sure if this is just a chrome issue. >>>> >>>> Thanks >>>> >>>> On Tue, Sep 16, 2014 at 2:09 PM, Adam Hughes >>>> wrote: >>>> >>>>> Hey Min, >>>>> >>>>> This was some weird browser error. I hadn't thought to reboot my >>>>> system, but indeed it was something with my system. Sorry for being too >>>>> dense to think to try this first! >>>>> >>>>> On Tue, Sep 16, 2014 at 2:02 PM, Adam Hughes >>>>> wrote: >>>>> >>>>>> # On branch 2.x >>>>>> # Your branch is up-to-date with 'origin/2.x'. >>>>>> # >>>>>> # Untracked files: >>>>>> # (use "git add ..." to include in what will be committed) >>>>>> # >>>>>> # Untitled0.ipynb >>>>>> # Untitled1.ipynb >>>>>> # Untitled2.ipynb >>>>>> # Untitled3.ipynb >>>>>> # >>>>>> nothing added to commit but untracked files present (use "git add" to >>>>>> track) >>>>>> glue at glue-desktop:~/ipython$ git submodule status >>>>>> 47ed6b9e18670a0d653d99e97e6165c14dd14047 >>>>>> IPython/html/static/components (2.1.0) >>>>>> glue at glue-desktop:~/ipython$ >>>>>> >>>>>> >>>>>> On Tue, Sep 16, 2014 at 1:55 PM, MinRK wrote: >>>>>> >>>>>>> What do you get from git status and git submodule status? >>>>>>> ? >>>>>>> >>>>>>> On Tue, Sep 16, 2014 at 10:43 AM, Adam Hughes < >>>>>>> hughesadam87 at gmail.com> wrote: >>>>>>> >>>>>>>> Hi, >>>>>>>> >>>>>>>> I just updated to the new dev version, and ran python setup.py >>>>>>>> submodule as usual, then setup.py install. When I open a notebook, either >>>>>>>> new or pre-made, I get a blank window. I get this error: >>>>>>>> >>>>>>>> WARNING:tornado.access:404 GET /static/jqueryui.js (127.0.0.1) >>>>>>>> 0.72ms referer=http://localhost:8890/notebooks/Untitled0.ipynb >>>>>>>> >>>>>>>> I've updated tornado, and nothing happens. I've reverted back to >>>>>>>> ipython 2.3 and I still get this. I'm on ubuntu. >>>>>>>> >>>>>>>> My friend is using mac osx 10.7. Her notebook actually loadas, but >>>>>>>> runs her first cell, regardless of what's in it, the kernel freezes. IE >>>>>>>> the cell's indicator changes to a " * " and stays like that. >>>>>>>> >>>>>>>> Is anyone else experiences such issues? >>>>>>>> >>>>>>>> Here is my pip freeze output (note pip freeze still says on on >>>>>>>> ipython 3.0, but if I run ipython in the terminal, it starts as 2.3: >>>>>>>> >>>>>>>> Canopy==1.4.0.dev6600 >>>>>>>> Cython==0.21 >>>>>>>> Examples==7.3 >>>>>>>> Flask==0.10.1 >>>>>>>> Jinja2==2.7.3 >>>>>>>> MKL==10.3 >>>>>>>> Markdown==2.4.1 >>>>>>>> MarkupSafe==0.23 >>>>>>>> PIL==1.1.7 >>>>>>>> PySide==1.2.1 >>>>>>>> PyYAML==3.11 >>>>>>>> Pygments==1.6.0 >>>>>>>> PythonDoc==2.7.3 >>>>>>>> Qt==4.8.5 >>>>>>>> Shapely==1.3.2 >>>>>>>> VTK==5.10.1 >>>>>>>> Werkzeug==0.9.6 >>>>>>>> appinst==2.1.2 >>>>>>>> apptools==4.2.1 >>>>>>>> atom==0.3.9 >>>>>>>> backports.ssl-match-hostname==3.4.0.2 >>>>>>>> basemap==1.0.7 >>>>>>>> bokeh==0.5.2 >>>>>>>> casuarius==1.1 >>>>>>>> certifi==14.05.14 >>>>>>>> chaco==4.4.1 >>>>>>>> cloud==2.4.6 >>>>>>>> colorama==0.3.1 >>>>>>>> configobj==5.0.6 >>>>>>>> coverage==3.7.1 >>>>>>>> docutils==0.11 >>>>>>>> enable==4.4.1 >>>>>>>> enaml==0.9.5 >>>>>>>> encore==0.5.1 >>>>>>>> enstaller==4.6.5 >>>>>>>> envisage==4.4.0 >>>>>>>> esky==0.9.8dev >>>>>>>> etsproxy==0.1.2 >>>>>>>> faulthandler==2.2 >>>>>>>> feedparser==5.1.3 >>>>>>>> freetype==2.5.3 >>>>>>>> geopandas==0.1.0.dev-35c2f5b >>>>>>>> gevent==1.0.1 >>>>>>>> gevent-websocket==0.9.3 >>>>>>>> glib==2.36.1 >>>>>>>> gnureadline==6.2.5 >>>>>>>> greenlet==0.4.3 >>>>>>>> grits-client==0.1 >>>>>>>> gst-plugins-bad==0.10.23 >>>>>>>> gst-plugins-base==0.10.36 >>>>>>>> gst-plugins-good==0.10.30 >>>>>>>> gstreamer==0.10.36 >>>>>>>> idle==2.7.3 >>>>>>>> ipython==3.0.0-dev >>>>>>>> itsdangerous==0.24 >>>>>>>> jdcal==1.0 >>>>>>>> jsonpickle==0.4.0 >>>>>>>> jsonpointer==1.4 >>>>>>>> jsonschema==2.3.0 >>>>>>>> kernmagic==0.2.0 >>>>>>>> keyring==3.6dev >>>>>>>> kiwisolver==0.1.2 >>>>>>>> libffi==3.0.13 >>>>>>>> libgfortran==3.0.0 >>>>>>>> libjpeg==7.0 >>>>>>>> libjpeg62==6.2 >>>>>>>> libncurses==5.9 >>>>>>>> libogg==1.3.0 >>>>>>>> libpng==1.6.12 >>>>>>>> libtheora==1.1.1 >>>>>>>> libvpx==1.1.0 >>>>>>>> libxml2==2.7.8 >>>>>>>> matplotlib==1.4.0 >>>>>>>> mayavi==4.3.1 >>>>>>>> mock==1.0.1 >>>>>>>> nbopen==0.1 >>>>>>>> nmrglue==0.4 >>>>>>>> nose==1.3.3 >>>>>>>> numpy==1.8.2 >>>>>>>> openpyxl==2.0.3 >>>>>>>> pandas==0.14.0 >>>>>>>> patsy==0.2.1 >>>>>>>> plotly==1.1.4 >>>>>>>> ply==3.4 >>>>>>>> psutil==1.2.1 >>>>>>>> pyaudio==0.2.4 >>>>>>>> pyface==4.4.0 >>>>>>>> pyflakes==0.7.3 >>>>>>>> pyglet==1.1.4 >>>>>>>> pyparsing==2.0.2 >>>>>>>> -e git+ >>>>>>>> https://github.com/hugadams/pyparty.git at e719a2c21d0e9ee32d36347792572bd61571de21#egg=pyparty-master >>>>>>>> pyproj==1.9.3 >>>>>>>> pysdmx==0.1 >>>>>>>> pystache==0.5.4 >>>>>>>> python-dateutil==2.2.0 >>>>>>>> pytz==2013b >>>>>>>> -e git+ >>>>>>>> https://github.com/hugadams/pyuvvis.git at a40befc64b0ac8a18d344d0e40b32b2b68dc3128#egg=pyuvvis-master >>>>>>>> pyzmq==14.3.1 >>>>>>>> readline==6.2.4.1 >>>>>>>> redis==2.10.3 >>>>>>>> requests==2.2.1 >>>>>>>> restview==2.0.5 >>>>>>>> runipy==0.1.0 >>>>>>>> scikit-learn==0.14.1 >>>>>>>> scikits.image==0.9.3 >>>>>>>> scipy==0.14.0 >>>>>>>> shiboken==1.2.1 >>>>>>>> six==1.7.3 >>>>>>>> ssl-match-hostname==3.4.0.2 >>>>>>>> statsmodels==0.5.0 >>>>>>>> supplement==0.5dev.dev202 >>>>>>>> svgwrite==1.1.2 >>>>>>>> sympy==0.7.5 >>>>>>>> tornado==4.0.2 >>>>>>>> traits==4.5.0 >>>>>>>> traitsui==4.4.0 >>>>>>>> websocket==0.2.1 >>>>>>>> wsgiref==0.1.2 >>>>>>>> wxPython==2.8.10.1 >>>>>>>> xray==0.1.1 >>>>>>>> zeromq==4.0.4 >>>>>>>> zlib==1.2.6 >>>>>>>> >>>>>>>> >>>>>>>> >>>>>>>> _______________________________________________ >>>>>>>> IPython-dev mailing list >>>>>>>> IPython-dev at scipy.org >>>>>>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>>>>>> >>>>>>>> >>>>>>> >>>>>>> _______________________________________________ >>>>>>> IPython-dev mailing list >>>>>>> IPython-dev at scipy.org >>>>>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>>>>> >>>>>>> >>>>>> >>>>> >>>> >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > > -- > Fernando Perez (@fperez_org; http://fperez.org) > fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) > fernando.perez-at-berkeley: contact me here for any direct mail > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From ellisonbg at gmail.com Tue Sep 16 15:10:51 2014 From: ellisonbg at gmail.com (Brian Granger) Date: Tue, 16 Sep 2014 12:10:51 -0700 Subject: [IPython-dev] Widget example that uses classes instead of globals? In-Reply-To: References: <-1189340719239998470@unknownmsgid> Message-ID: https://github.com/ellisonbg/leaftletwidget/blob/master/leafletwidget/leaflet.py#L19 This mixin provides an interact method that allows you to interact with any traitlet on a class. Just haven't had time to turn this into a proper ipython PR... On Tue, Sep 16, 2014 at 11:27 AM, Adam Hughes wrote: > Nicholas, > > This is an amazing example. Thanks so much for helping us this much! Will > send you some updates when we are able to get it running with our data and > credit you in this. Is there a special way you'd like to be acknowledged or > cited? > > On Mon, Sep 15, 2014 at 11:19 PM, Nicholas Bollweg > wrote: >> >> @antonino: I hadn't thought to use interact that way! __call__ might be >> too magic to be used that way... but you can create a non-bound function >> (not a method, though self would be in scope!) in the constructor of a >> widget that will respond to interact: >> >>> from IPython.html.widgets import interact, ContainerWidget, HTMLWidget >>> >>> class Carousel(ContainerWidget): >>> def __init__(self, *args, **kwargs): >>> self.might_show = [HTMLWidget(value="

%s

" % i) for i in >>> range(10)] >>> super(Carousel, self).__init__(*args, **kwargs) >>> >>> def interact(n): >>> self.children = [self.might_show[n]] >>> >>> self.show = show >>> >>> carousel = Carousel() >>> interact(carousel.interact, n=(0, len(carousel.might_show)-1)) >>> carousel >> >> >> I don't know much about how matplotlib interacts with widgets/traitlets... >> but presumably the ImageWidget will accept them as its value. >> >> You could move even more behavior into the class itself, but eventually >> one would likely need something more complicated than what interact provides >> out of the box... >> >> @adam: Sorry it took me a while to respond. Here is an updated version of >> the fake GUI, implemented as a series of classes: a standalone graph, a >> couple reusable control components and the full-blown end user GUI. I tried >> to put a few examples of different techniques in that we have used: link, >> on_trait_changed, CSS, Bootstrap. I didn't do any custom Backbone, as that >> is a whole other kettle of fish. >> >>> http://nbviewer.ipython.org/gist/bollwyvl/ddd4bf5d7c879012fa2c >> >> >> There are a few more gotchas that would come along with this, such as >> installing assets, if you end up using them, but there are a good number of >> threads/examples out there for install_nbextension/load_nbextensions. In a >> pinch, you could even cheat and have an HTML embed the style directly, I >> guess! >> >> I didn't use the "wire" concept from before: while it has proven useful >> for quickly hacking stuff together, i have found it might be a bit "cute" >> for something that one actually wanted to release and/or expect people to be >> able to extend. If i can figure out how to get it to easily un-listen for >> things, it might be work saving, but in the meantime link and >> on_trait_changed are good enough! >> >> Hope this helps! >> >> On Sat, Aug 30, 2014 at 2:21 PM, Antonino Ingargiola >> wrote: >>> >>> Hi, >>> >>> Sorry for entering in the discussion on-fly... >>> >>> My question is more specific (but possibly very similar). Would be >>> possible to call interact with a class object (i.e. a callable class) >>> instead of a function? This would allow to store all the GUI specific state >>> in the class (for example precomputing figures) without the need of using >>> globals. >>> >>> When I quickly tried (with ipython 2.2), interact returned an error >>> complaining about the number of parameters passed to the object. So I >>> resorted to using globals. Below I attached the code I currently use to >>> pre-compute a set of figures (a slider selects which figure to display). I >>> would appreciate any comment on possibly improving this pattern. >>> >>> fig_cache = {} >>> def plot_mfit_i(ich=0, nodisplay=False): >>> global fig_cache >>> if ich not in fig_cache: >>> fig = mfit.plot_mfit(fitter, ich=ich, residuals=True, >>> return_fig=True) >>> fig_cache[ich] = fig >>> plt.close(fig) >>> if not nodisplay: >>> display(fig_cache[ich]) >>> >>> for i in range(8): plot_mfit_i(i, nodisplay=True) # Precompute all the >>> figures >>> >>> interact(plot_mfit_i, ich=(0, 7), nodisplay=fixed(False)); # display the >>> figure selected through the slider >>> >>> -- >>> Antonio >>> >>> On Sat, Aug 30, 2014 at 10:49 AM, Cyrille Rossant >>> wrote: >>>> >>>> I think you can use the "display" function to render a widget instance, >>>> does that answer your question? >>>> ________________________________ >>>> De : Adam Hughes >>>> Envoy? : ?30/?08/?2014 18:43 >>>> ? : IPython developers list >>>> Objet : Re: [IPython-dev] Widget example that uses classes instead of >>>> globals? >>>> >>>> And just to clarify, I presume that the notebook is actively "looking" >>>> for particular functions or something in the cell that let's the notebook >>>> know "hey, this is widget/GUI code, I need to output it as so". I had >>>> worried that if this critical piece was buried in a class, the notebook >>>> wouldn't recognize it, and the GUI wouldn't display. >>>> >>>> >>>> On Sat, Aug 30, 2014 at 1:41 PM, Adam Hughes >>>> wrote: >>>>> >>>>> Hi, >>>>> >>>>> This question follows directly from this recent thread on the >>>>> feasiblity of widgets >>>>> (http://python.6.x6.nabble.com/Feasilibity-of-widgets-layout-for-mimicking-this-td5068197.html) >>>>> but I thought was specific enough to be a new thread. >>>>> >>>>> In all of the notebook examples I've seen, a GUI is defined in its own >>>>> cell with global variables that are shared between functions. I'd really >>>>> like to see a complete, simple example of a GUI build as a class, where most >>>>> of the events, updates and default values are set within the class. And >>>>> then when the class is instantiated, the notebook somehow can still output >>>>> the GUI. >>>>> >>>>> For example, would something of this design be compatible with the >>>>> current widget design pattern: >>>>> >>>>> class Foo(object): >>>>> >>>>> variable = defaultvalue >>>>> >>>>> def update_variable(self): >>>>> .... >>>>> >>>>> def redraw(self): >>>>> ... >>>>> >>>>> # Instantiate the class >>>>> f = Foo() >>>>> f.variable_widget.on_trait_change(update_variable, 'value') >>>>> >>>>> Or is this type of design pattern out of the question? We're trying to >>>>> move in this direction so that we can compartmentalize and template as much >>>>> behavior as possible, and make a simple framework for building up more >>>>> complex GUIs. It's just now clear to me if such a pattern is possible. If >>>>> anyone has any insights or examples, would you mind sharing? >>>>> >>>>> THanks >>>> >>>> >>>> >>>> _______________________________________________ >>>> IPython-dev mailing list >>>> IPython-dev at scipy.org >>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>> >>> >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -- Brian E. Granger Cal Poly State University, San Luis Obispo @ellisonbg on Twitter and GitHub bgranger at calpoly.edu and ellisonbg at gmail.com From benjaminrk at gmail.com Tue Sep 16 15:12:07 2014 From: benjaminrk at gmail.com (MinRK) Date: Tue, 16 Sep 2014 12:12:07 -0700 Subject: [IPython-dev] KaTeX (alternative to mathjax?) In-Reply-To: References: Message-ID: It's definitely exciting, but we should be a bit conservative and watch how it goes for a bit before adopting it. Large book-style notebooks definitely observer slow mathax, especially on nbviewer. -MinRK On Tue, Sep 16, 2014 at 11:21 AM, Andrew Gibiansky < andrew.gibiansky at gmail.com> wrote: > I have some questions that are not answered well on that page: > > > - Is the only advantage over MathJax speed? If so, the fact that > IPython notebooks are typically used in cells reduces the usefulness > somewhat, as I usually only need to revaluate smallish cells. (Of course, > maybe using this for nbconvert output would be useful....) > - Does it render all of the same code as MathJax would? e.g. do things > like \begin{align*} ... \end{align*} still work? > - Are there things that KaTeX does that MathJax does *not*, besides > speed? > > I think these questions would be important to answer before using it. > > -- Andrew > > On Tue, Sep 16, 2014 at 11:16 AM, Neal Becker wrote: > >> http://khan.github.io/KaTeX/ >> >> -- >> -- Those who don't understand recursion are doomed to repeat it >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From benjaminrk at gmail.com Tue Sep 16 15:12:07 2014 From: benjaminrk at gmail.com (MinRK) Date: Tue, 16 Sep 2014 12:12:07 -0700 Subject: [IPython-dev] KaTeX (alternative to mathjax?) In-Reply-To: References: Message-ID: It's definitely exciting, but we should be a bit conservative and watch how it goes for a bit before adopting it. Large book-style notebooks definitely observer slow mathax, especially on nbviewer. -MinRK On Tue, Sep 16, 2014 at 11:21 AM, Andrew Gibiansky < andrew.gibiansky at gmail.com> wrote: > I have some questions that are not answered well on that page: > > > - Is the only advantage over MathJax speed? If so, the fact that > IPython notebooks are typically used in cells reduces the usefulness > somewhat, as I usually only need to revaluate smallish cells. (Of course, > maybe using this for nbconvert output would be useful....) > - Does it render all of the same code as MathJax would? e.g. do things > like \begin{align*} ... \end{align*} still work? > - Are there things that KaTeX does that MathJax does *not*, besides > speed? > > I think these questions would be important to answer before using it. > > -- Andrew > > On Tue, Sep 16, 2014 at 11:16 AM, Neal Becker wrote: > >> http://khan.github.io/KaTeX/ >> >> -- >> -- Those who don't understand recursion are doomed to repeat it >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From hughesadam87 at gmail.com Tue Sep 16 15:16:06 2014 From: hughesadam87 at gmail.com (Adam Hughes) Date: Tue, 16 Sep 2014 15:16:06 -0400 Subject: [IPython-dev] Widget example that uses classes instead of globals? In-Reply-To: References: <-1189340719239998470@unknownmsgid> Message-ID: Brian, thanks. I am a bit overwhelmed with the amount of info I'm receiving, so will need some time to parse it all. Looking forward to getting my feet wet. On Tue, Sep 16, 2014 at 3:10 PM, Brian Granger wrote: > > https://github.com/ellisonbg/leaftletwidget/blob/master/leafletwidget/leaflet.py#L19 > > This mixin provides an interact method that allows you to interact > with any traitlet on a class. Just haven't had time to turn this into > a proper ipython PR... > > On Tue, Sep 16, 2014 at 11:27 AM, Adam Hughes > wrote: > > Nicholas, > > > > This is an amazing example. Thanks so much for helping us this much! > Will > > send you some updates when we are able to get it running with our data > and > > credit you in this. Is there a special way you'd like to be > acknowledged or > > cited? > > > > On Mon, Sep 15, 2014 at 11:19 PM, Nicholas Bollweg < > nick.bollweg at gmail.com> > > wrote: > >> > >> @antonino: I hadn't thought to use interact that way! __call__ might be > >> too magic to be used that way... but you can create a non-bound function > >> (not a method, though self would be in scope!) in the constructor of a > >> widget that will respond to interact: > >> > >>> from IPython.html.widgets import interact, ContainerWidget, HTMLWidget > >>> > >>> class Carousel(ContainerWidget): > >>> def __init__(self, *args, **kwargs): > >>> self.might_show = [HTMLWidget(value="

%s

" % i) for i in > >>> range(10)] > >>> super(Carousel, self).__init__(*args, **kwargs) > >>> > >>> def interact(n): > >>> self.children = [self.might_show[n]] > >>> > >>> self.show = show > >>> > >>> carousel = Carousel() > >>> interact(carousel.interact, n=(0, len(carousel.might_show)-1)) > >>> carousel > >> > >> > >> I don't know much about how matplotlib interacts with > widgets/traitlets... > >> but presumably the ImageWidget will accept them as its value. > >> > >> You could move even more behavior into the class itself, but eventually > >> one would likely need something more complicated than what interact > provides > >> out of the box... > >> > >> @adam: Sorry it took me a while to respond. Here is an updated version > of > >> the fake GUI, implemented as a series of classes: a standalone graph, a > >> couple reusable control components and the full-blown end user GUI. I > tried > >> to put a few examples of different techniques in that we have used: > link, > >> on_trait_changed, CSS, Bootstrap. I didn't do any custom Backbone, as > that > >> is a whole other kettle of fish. > >> > >>> http://nbviewer.ipython.org/gist/bollwyvl/ddd4bf5d7c879012fa2c > >> > >> > >> There are a few more gotchas that would come along with this, such as > >> installing assets, if you end up using them, but there are a good > number of > >> threads/examples out there for install_nbextension/load_nbextensions. > In a > >> pinch, you could even cheat and have an HTML embed the style directly, I > >> guess! > >> > >> I didn't use the "wire" concept from before: while it has proven useful > >> for quickly hacking stuff together, i have found it might be a bit > "cute" > >> for something that one actually wanted to release and/or expect people > to be > >> able to extend. If i can figure out how to get it to easily un-listen > for > >> things, it might be work saving, but in the meantime link and > >> on_trait_changed are good enough! > >> > >> Hope this helps! > >> > >> On Sat, Aug 30, 2014 at 2:21 PM, Antonino Ingargiola < > tritemio at gmail.com> > >> wrote: > >>> > >>> Hi, > >>> > >>> Sorry for entering in the discussion on-fly... > >>> > >>> My question is more specific (but possibly very similar). Would be > >>> possible to call interact with a class object (i.e. a callable class) > >>> instead of a function? This would allow to store all the GUI specific > state > >>> in the class (for example precomputing figures) without the need of > using > >>> globals. > >>> > >>> When I quickly tried (with ipython 2.2), interact returned an error > >>> complaining about the number of parameters passed to the object. So I > >>> resorted to using globals. Below I attached the code I currently use to > >>> pre-compute a set of figures (a slider selects which figure to > display). I > >>> would appreciate any comment on possibly improving this pattern. > >>> > >>> fig_cache = {} > >>> def plot_mfit_i(ich=0, nodisplay=False): > >>> global fig_cache > >>> if ich not in fig_cache: > >>> fig = mfit.plot_mfit(fitter, ich=ich, residuals=True, > >>> return_fig=True) > >>> fig_cache[ich] = fig > >>> plt.close(fig) > >>> if not nodisplay: > >>> display(fig_cache[ich]) > >>> > >>> for i in range(8): plot_mfit_i(i, nodisplay=True) # Precompute all the > >>> figures > >>> > >>> interact(plot_mfit_i, ich=(0, 7), nodisplay=fixed(False)); # display > the > >>> figure selected through the slider > >>> > >>> -- > >>> Antonio > >>> > >>> On Sat, Aug 30, 2014 at 10:49 AM, Cyrille Rossant > >>> wrote: > >>>> > >>>> I think you can use the "display" function to render a widget > instance, > >>>> does that answer your question? > >>>> ________________________________ > >>>> De : Adam Hughes > >>>> Envoy? : ?30/?08/?2014 18:43 > >>>> ? : IPython developers list > >>>> Objet : Re: [IPython-dev] Widget example that uses classes instead of > >>>> globals? > >>>> > >>>> And just to clarify, I presume that the notebook is actively "looking" > >>>> for particular functions or something in the cell that let's the > notebook > >>>> know "hey, this is widget/GUI code, I need to output it as so". I had > >>>> worried that if this critical piece was buried in a class, the > notebook > >>>> wouldn't recognize it, and the GUI wouldn't display. > >>>> > >>>> > >>>> On Sat, Aug 30, 2014 at 1:41 PM, Adam Hughes > >>>> wrote: > >>>>> > >>>>> Hi, > >>>>> > >>>>> This question follows directly from this recent thread on the > >>>>> feasiblity of widgets > >>>>> ( > http://python.6.x6.nabble.com/Feasilibity-of-widgets-layout-for-mimicking-this-td5068197.html > ) > >>>>> but I thought was specific enough to be a new thread. > >>>>> > >>>>> In all of the notebook examples I've seen, a GUI is defined in its > own > >>>>> cell with global variables that are shared between functions. I'd > really > >>>>> like to see a complete, simple example of a GUI build as a class, > where most > >>>>> of the events, updates and default values are set within the class. > And > >>>>> then when the class is instantiated, the notebook somehow can still > output > >>>>> the GUI. > >>>>> > >>>>> For example, would something of this design be compatible with the > >>>>> current widget design pattern: > >>>>> > >>>>> class Foo(object): > >>>>> > >>>>> variable = defaultvalue > >>>>> > >>>>> def update_variable(self): > >>>>> .... > >>>>> > >>>>> def redraw(self): > >>>>> ... > >>>>> > >>>>> # Instantiate the class > >>>>> f = Foo() > >>>>> f.variable_widget.on_trait_change(update_variable, 'value') > >>>>> > >>>>> Or is this type of design pattern out of the question? We're trying > to > >>>>> move in this direction so that we can compartmentalize and template > as much > >>>>> behavior as possible, and make a simple framework for building up > more > >>>>> complex GUIs. It's just now clear to me if such a pattern is > possible. If > >>>>> anyone has any insights or examples, would you mind sharing? > >>>>> > >>>>> THanks > >>>> > >>>> > >>>> > >>>> _______________________________________________ > >>>> IPython-dev mailing list > >>>> IPython-dev at scipy.org > >>>> http://mail.scipy.org/mailman/listinfo/ipython-dev > >>>> > >>> > >>> > >>> _______________________________________________ > >>> IPython-dev mailing list > >>> IPython-dev at scipy.org > >>> http://mail.scipy.org/mailman/listinfo/ipython-dev > >>> > >> > >> > >> _______________________________________________ > >> IPython-dev mailing list > >> IPython-dev at scipy.org > >> http://mail.scipy.org/mailman/listinfo/ipython-dev > >> > > > > > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > > > -- > Brian E. Granger > Cal Poly State University, San Luis Obispo > @ellisonbg on Twitter and GitHub > bgranger at calpoly.edu and ellisonbg at gmail.com > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: From fperez.net at gmail.com Tue Sep 16 15:22:24 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Tue, 16 Sep 2014 12:22:24 -0700 Subject: [IPython-dev] Widget example that uses classes instead of globals? In-Reply-To: References: <-1189340719239998470@unknownmsgid> Message-ID: On Mon, Sep 15, 2014 at 8:19 PM, Nicholas Bollweg wrote: > @adam: Sorry it took me a while to respond. Here is an updated version of > the fake GUI, implemented as a series of classes: a standalone graph, a > couple reusable control components and the full-blown end user GUI. I tried > to put a few examples of different techniques in that we have used: link, > on_trait_changed, CSS, Bootstrap. I didn't do any custom Backbone, as that > is a whole other kettle of fish. > > >> >> http://nbviewer.ipython.org/gist/bollwyvl/ddd4bf5d7c879012fa2c >> > Wonderful example, thanks Nicholas! I've made a minimally modified version here: https://gist.github.com/fperez/c65b06b260bde5663dbf just to illustrate how to actually plot data in the 'plot area' with matplotlib. I may use this in a talk I'm giving tomorrow, if so I'll do so with full credit to you. Thanks for sharing! f -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: From felix at fbreuer.de Tue Sep 16 16:34:05 2014 From: felix at fbreuer.de (Felix Breuer) Date: Tue, 16 Sep 2014 22:34:05 +0200 Subject: [IPython-dev] KaTeX (alternative to mathjax?) In-Reply-To: References: Message-ID: KaTeX does not support matrices, arrays, etc. Also, MathJax will see speed improvements in the next release. See https://groups.google.com/d/topic/mathjax-users/vStfa_uxbCk/discussion -- Felix On 16 Sep 2014, at 21:12, MinRK wrote: > It's definitely exciting, but we should be a bit conservative and watch how it goes for a bit before adopting it. Large book-style notebooks definitely observer slow mathax, especially on nbviewer. > > -MinRK > > On Tue, Sep 16, 2014 at 11:21 AM, Andrew Gibiansky wrote: > I have some questions that are not answered well on that page: > > Is the only advantage over MathJax speed? If so, the fact that IPython notebooks are typically used in cells reduces the usefulness somewhat, as I usually only need to revaluate smallish cells. (Of course, maybe using this for nbconvert output would be useful....) > Does it render all of the same code as MathJax would? e.g. do things like \begin{align*} ... \end{align*} still work? > Are there things that KaTeX does that MathJax does not, besides speed? > I think these questions would be important to answer before using it. > > -- Andrew > > On Tue, Sep 16, 2014 at 11:16 AM, Neal Becker wrote: > http://khan.github.io/KaTeX/ > > -- > -- Those who don't understand recursion are doomed to repeat it > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: From felix at fbreuer.de Tue Sep 16 16:34:05 2014 From: felix at fbreuer.de (Felix Breuer) Date: Tue, 16 Sep 2014 22:34:05 +0200 Subject: [IPython-dev] KaTeX (alternative to mathjax?) In-Reply-To: References: Message-ID: KaTeX does not support matrices, arrays, etc. Also, MathJax will see speed improvements in the next release. See https://groups.google.com/d/topic/mathjax-users/vStfa_uxbCk/discussion -- Felix On 16 Sep 2014, at 21:12, MinRK wrote: > It's definitely exciting, but we should be a bit conservative and watch how it goes for a bit before adopting it. Large book-style notebooks definitely observer slow mathax, especially on nbviewer. > > -MinRK > > On Tue, Sep 16, 2014 at 11:21 AM, Andrew Gibiansky wrote: > I have some questions that are not answered well on that page: > > Is the only advantage over MathJax speed? If so, the fact that IPython notebooks are typically used in cells reduces the usefulness somewhat, as I usually only need to revaluate smallish cells. (Of course, maybe using this for nbconvert output would be useful....) > Does it render all of the same code as MathJax would? e.g. do things like \begin{align*} ... \end{align*} still work? > Are there things that KaTeX does that MathJax does not, besides speed? > I think these questions would be important to answer before using it. > > -- Andrew > > On Tue, Sep 16, 2014 at 11:16 AM, Neal Becker wrote: > http://khan.github.io/KaTeX/ > > -- > -- Those who don't understand recursion are doomed to repeat it > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: From asmeurer at gmail.com Tue Sep 16 16:37:51 2014 From: asmeurer at gmail.com (Aaron Meurer) Date: Tue, 16 Sep 2014 15:37:51 -0500 Subject: [IPython-dev] KaTeX (alternative to mathjax?) In-Reply-To: References: Message-ID: Does anyone know of any pages comparing rendering output of KaTeX and MathJax? And yes, it apparently does lack support for things like \begin{anything} and even some symbols like \nabla, so I would hold out on replacing it outright, although I imagine you may want to eventually allow to choose it as an alternate backend to MathJax. Aaron Meurer On Tue, Sep 16, 2014 at 3:34 PM, Felix Breuer wrote: > KaTeX does not support matrices, arrays, etc. Also, MathJax will see speed > improvements in the next release. See > > https://groups.google.com/d/topic/mathjax-users/vStfa_uxbCk/discussion > > -- Felix > > > > On 16 Sep 2014, at 21:12, MinRK wrote: > > It's definitely exciting, but we should be a bit conservative and watch how > it goes for a bit before adopting it. Large book-style notebooks definitely > observer slow mathax, especially on nbviewer. > > -MinRK > > On Tue, Sep 16, 2014 at 11:21 AM, Andrew Gibiansky > wrote: >> >> I have some questions that are not answered well on that page: >> >> Is the only advantage over MathJax speed? If so, the fact that IPython >> notebooks are typically used in cells reduces the usefulness somewhat, as I >> usually only need to revaluate smallish cells. (Of course, maybe using this >> for nbconvert output would be useful....) >> Does it render all of the same code as MathJax would? e.g. do things like >> \begin{align*} ... \end{align*} still work? >> Are there things that KaTeX does that MathJax does not, besides speed? >> >> I think these questions would be important to answer before using it. >> >> -- Andrew >> >> On Tue, Sep 16, 2014 at 11:16 AM, Neal Becker wrote: >>> >>> http://khan.github.io/KaTeX/ >>> >>> -- >>> -- Those who don't understand recursion are doomed to repeat it >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > From asmeurer at gmail.com Tue Sep 16 16:37:51 2014 From: asmeurer at gmail.com (Aaron Meurer) Date: Tue, 16 Sep 2014 15:37:51 -0500 Subject: [IPython-dev] KaTeX (alternative to mathjax?) In-Reply-To: References: Message-ID: Does anyone know of any pages comparing rendering output of KaTeX and MathJax? And yes, it apparently does lack support for things like \begin{anything} and even some symbols like \nabla, so I would hold out on replacing it outright, although I imagine you may want to eventually allow to choose it as an alternate backend to MathJax. Aaron Meurer On Tue, Sep 16, 2014 at 3:34 PM, Felix Breuer wrote: > KaTeX does not support matrices, arrays, etc. Also, MathJax will see speed > improvements in the next release. See > > https://groups.google.com/d/topic/mathjax-users/vStfa_uxbCk/discussion > > -- Felix > > > > On 16 Sep 2014, at 21:12, MinRK wrote: > > It's definitely exciting, but we should be a bit conservative and watch how > it goes for a bit before adopting it. Large book-style notebooks definitely > observer slow mathax, especially on nbviewer. > > -MinRK > > On Tue, Sep 16, 2014 at 11:21 AM, Andrew Gibiansky > wrote: >> >> I have some questions that are not answered well on that page: >> >> Is the only advantage over MathJax speed? If so, the fact that IPython >> notebooks are typically used in cells reduces the usefulness somewhat, as I >> usually only need to revaluate smallish cells. (Of course, maybe using this >> for nbconvert output would be useful....) >> Does it render all of the same code as MathJax would? e.g. do things like >> \begin{align*} ... \end{align*} still work? >> Are there things that KaTeX does that MathJax does not, besides speed? >> >> I think these questions would be important to answer before using it. >> >> -- Andrew >> >> On Tue, Sep 16, 2014 at 11:16 AM, Neal Becker wrote: >>> >>> http://khan.github.io/KaTeX/ >>> >>> -- >>> -- Those who don't understand recursion are doomed to repeat it >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > From hughesadam87 at gmail.com Tue Sep 16 17:10:04 2014 From: hughesadam87 at gmail.com (Adam Hughes) Date: Tue, 16 Sep 2014 17:10:04 -0400 Subject: [IPython-dev] Widget example that uses classes instead of globals? In-Reply-To: References: <-1189340719239998470@unknownmsgid> Message-ID: I wanted to share a bit of context for this example, since it has been seen by several of you on the list. We are looking to implement a spectroscopy field called two-dimensional correlation analysis. I spoke with the founder of the subject, and he said he's only aware of a small, windows program that essentially is this GUI. In fact, the original screenshot I sent was from that small program. A matlab program called MIDAS also did a really job of porting some 2DCS principles. We've built 2DCS directly into our new spectroscopy library, so being able to give users a GUI-driven experience ON TOP OF the pandas-based API is our golden ticket. This vision of GUI when you want it, API when you need it in the notebook I hope will catch on. I really am appreciative of all of the help you guys gave me on this thread an hope to deliver. Here is the analysis through the API if it's interesting to anyone. http://nbviewer.ipython.org/github/hugadams/pyuvvis/blob/master/examples/Notebooks/correlation_p1.ipynb This is also just an incomplete draft. On Tue, Sep 16, 2014 at 3:22 PM, Fernando Perez wrote: > > On Mon, Sep 15, 2014 at 8:19 PM, Nicholas Bollweg > wrote: > >> @adam: Sorry it took me a while to respond. Here is an updated version of >> the fake GUI, implemented as a series of classes: a standalone graph, a >> couple reusable control components and the full-blown end user GUI. I tried >> to put a few examples of different techniques in that we have used: link, >> on_trait_changed, CSS, Bootstrap. I didn't do any custom Backbone, as that >> is a whole other kettle of fish. >> >> >>> >>> http://nbviewer.ipython.org/gist/bollwyvl/ddd4bf5d7c879012fa2c >>> >> > Wonderful example, thanks Nicholas! > > I've made a minimally modified version here: > > https://gist.github.com/fperez/c65b06b260bde5663dbf > > just to illustrate how to actually plot data in the 'plot area' with > matplotlib. > > I may use this in a talk I'm giving tomorrow, if so I'll do so with full > credit to you. > > Thanks for sharing! > > f > > > -- > Fernando Perez (@fperez_org; http://fperez.org) > fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) > fernando.perez-at-berkeley: contact me here for any direct mail > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From nick.bollweg at gmail.com Tue Sep 16 16:21:30 2014 From: nick.bollweg at gmail.com (Nicholas Bollweg) Date: Tue, 16 Sep 2014 16:21:30 -0400 Subject: [IPython-dev] Widget example that uses classes instead of globals? In-Reply-To: References: <-1189340719239998470@unknownmsgid> Message-ID: @adam No problem, no special acknowledgement necessary! The credit goes to the creators of the Notebook and its ecosystem (bootstrap, backbone, etc): as a user, I feel much better about the result of this little exercise vs. other forays into, say, wx, Flash/Flex, to create similar things. Certainly do keep us posted on your progress! @brian leafletwidget: i've needed this in the past! thanks for the link! > offtopic: where's the bower.io for widgets!? how would it look in the > jupyter future? > the mixin looks better for antonino's broader question, as well. Do you like the approach you have taken for treating the widget js as a template, inserted into the notebook output? is this a better way to do it than load_extensons? will this be better for static widgets, or will stuff from load_extensions be included? @fernando Making it less notional is a great upgrade, and i'll likely add a link to your expanded version. I think we still want some examples that are even less notional (i.e. useful!), but happy to help! On Tue, Sep 16, 2014 at 3:22 PM, Fernando Perez wrote: > > On Mon, Sep 15, 2014 at 8:19 PM, Nicholas Bollweg > wrote: > >> @adam: Sorry it took me a while to respond. Here is an updated version of >> the fake GUI, implemented as a series of classes: a standalone graph, a >> couple reusable control components and the full-blown end user GUI. I tried >> to put a few examples of different techniques in that we have used: link, >> on_trait_changed, CSS, Bootstrap. I didn't do any custom Backbone, as that >> is a whole other kettle of fish. >> >> >>> >>> http://nbviewer.ipython.org/gist/bollwyvl/ddd4bf5d7c879012fa2c >>> >> > Wonderful example, thanks Nicholas! > > I've made a minimally modified version here: > > https://gist.github.com/fperez/c65b06b260bde5663dbf > > just to illustrate how to actually plot data in the 'plot area' with > matplotlib. > > I may use this in a talk I'm giving tomorrow, if so I'll do so with full > credit to you. > > Thanks for sharing! > > f > > > -- > Fernando Perez (@fperez_org; http://fperez.org) > fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) > fernando.perez-at-berkeley: contact me here for any direct mail > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From benjaminrk at gmail.com Tue Sep 16 18:42:18 2014 From: benjaminrk at gmail.com (MinRK) Date: Tue, 16 Sep 2014 15:42:18 -0700 Subject: [IPython-dev] Jupyterhub with ssl? In-Reply-To: References: <54173A65.6020904@stanford.edu> <54173D4D.9020307@stanford.edu> Message-ID: It?s IPython?s websocket cross-origin checking getting confused by the proxied request. If you add: --NotebookApp.allow_origin=[https://your_host](https://your_host)[:port] (or ?*?) to the args passed to the single-user servers, it should allow the connection: jupyterhub --Spawner.cmd="['jupyterhub-singleuser', '--NotebookApp.allow_origin=https://your_host[:port]']" I opened a PR to patch the bug in origin checking. -MinRK ? On Mon, Sep 15, 2014 at 4:26 PM, MinRK wrote: > I'll look into it. Might be something wrong in the proxy config. > > On Mon, Sep 15, 2014 at 12:26 PM, Bob Dougherty wrote: > >> Thanks Matthias. Unfortunately, I get the same error on Firefox. And >> ipython without the hub works fine with ssl on Chrome. Does ssl through >> jupyterhub work for you? If so, what version of node are you running? >> >> >> On 09/15/2014 12:19 PM, Matthias Bussonnier wrote: >> >> >> Le 15 sept. 2014 ? 21:13, Bob Dougherty a ?crit : >> >> Hi All, >> >> Is anyone else running Jupyterhub through ssl? I'm struggling to get it >> working. Everything works fine except for the websocket connection. I.e., I >> can log in through the Jupyterhub login page, create, edit, save notebooks, >> etc. But trying to execute a code cell just hangs. Chrome shows this in the >> js console: >> >> Default extension for cell metadata editing loaded. >> Raw Cell Format toolbar preset loaded. >> Slideshow extension for metadata editing loaded. >> Kernel started: 398fe67c-856b-48c5-b2d7-242bfa70f2e1 >> Starting WebSockets: >> wss://spgr.stanford.edu:8080/user/bobd/api/kernels/398fe67c-856b-48c5-b2d7-242bfa70f2e1 >> Uncaught InvalidStateError: Failed to execute 'send' on 'WebSocket': >> Still in CONNECTING state. >> :8080/user/bobd/static/services/kernels/js/kernel.js:248 >> >> Everything *does* work when I don't use ssl, and ssl works (with the same >> cert and key) when I run the notebook directly without jupyterhub. So I >> suspect it's a problem with the nodejs proxy of wss. I'm running node >> v0.10.25 and the current master of jupyterhub and ipython. >> >> Any help on debugging this would be much appreciated! >> >> >> I got that on chrome, without jupyter-hub. Solved by itself after 1 >> week of holidays. >> My opinion is that it's a bug on chrome that sometime refuses to open 3 >> web socket connexions at the same time, >> as when it did happen firefox was happy with my setup. >> >> -- >> M >> >> >> >> thanks, >> bob >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> >> >> >> _______________________________________________ >> IPython-dev mailing listIPython-dev at scipy.orghttp://mail.scipy.org/mailman/listinfo/ipython-dev >> >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bobd at stanford.edu Tue Sep 16 18:55:38 2014 From: bobd at stanford.edu (Bob Dougherty) Date: Tue, 16 Sep 2014 15:55:38 -0700 Subject: [IPython-dev] Jupyterhub with ssl? In-Reply-To: References: <54173A65.6020904@stanford.edu> <54173D4D.9020307@stanford.edu> Message-ID: <5418BFEA.4030200@stanford.edu> Awesome! That works. Thanks Min! On 09/16/2014 03:42 PM, MinRK wrote: > > It?s IPython?s websocket cross-origin checking getting confused by the > proxied request. If you add: > > |--NotebookApp.allow_origin=[https://your_host](https://your_host)[:port] > | > > (or ?*?) > > to the args passed to the single-user servers, it should allow the > connection: > > |jupyterhub --Spawner.cmd="['jupyterhub-singleuser', '--NotebookApp.allow_origin=https://your_host[:port]']" > | > > I opened a PR to patch > the bug in origin checking. > > -MinRK > > ? > > On Mon, Sep 15, 2014 at 4:26 PM, MinRK > wrote: > > I'll look into it. Might be something wrong in the proxy config. > > On Mon, Sep 15, 2014 at 12:26 PM, Bob Dougherty > wrote: > > Thanks Matthias. Unfortunately, I get the same error on > Firefox. And ipython without the hub works fine with ssl on > Chrome. Does ssl through jupyterhub work for you? If so, what > version of node are you running? > > > On 09/15/2014 12:19 PM, Matthias Bussonnier wrote: >> >> Le 15 sept. 2014 ? 21:13, Bob Dougherty > > a ?crit : >> >>> Hi All, >>> >>> Is anyone else running Jupyterhub through ssl? I'm >>> struggling to get it working. Everything works fine except >>> for the websocket connection. I.e., I can log in through the >>> Jupyterhub login page, create, edit, save notebooks, etc. >>> But trying to execute a code cell just hangs. Chrome shows >>> this in the js console: >>> >>> Default extension for cell metadata editing loaded. >>> Raw Cell Format toolbar preset loaded. >>> Slideshow extension for metadata editing loaded. >>> Kernel started: 398fe67c-856b-48c5-b2d7-242bfa70f2e1 >>> Starting WebSockets: >>> wss://spgr.stanford.edu:8080/user/bobd/api/kernels/398fe67c-856b-48c5-b2d7-242bfa70f2e1 >>> Uncaught InvalidStateError: Failed to execute 'send' on >>> 'WebSocket': Still in CONNECTING state. >>> :8080/user/bobd/static/services/kernels/js/kernel.js:248 >>> >>> Everything *does* work when I don't use ssl, and ssl works >>> (with the same cert and key) when I run the notebook >>> directly without jupyterhub. So I suspect it's a problem >>> with the nodejs proxy of wss. I'm running node v0.10.25 and >>> the current master of jupyterhub and ipython. >>> >>> Any help on debugging this would be much appreciated! >> >> I got that on chrome, without jupyter-hub. Solved by itself >> after 1 week of holidays. >> My opinion is that it's a bug on chrome that sometime refuses >> to open 3 web socket connexions at the same time, >> as when it did happen firefox was happy with my setup. >> >> -- >> M >> >> >>> >>> thanks, >>> bob >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -- Robert F. Dougherty, PhD Research Director Stanford Center for Cognitive and Neurobiological Imaging 70 Jordan Hall * Stanford CA 94305 * 650-725-0051 http://www.stanford.edu/~bobd -------------- next part -------------- An HTML attachment was scrubbed... URL: From jsw at fnal.gov Thu Sep 18 17:10:10 2014 From: jsw at fnal.gov (Jon Wilson) Date: Thu, 18 Sep 2014 16:10:10 -0500 Subject: [IPython-dev] Renumber cells for nbconvert Message-ID: <541B4A32.20204@fnal.gov> Hi, We often share around nbconverted notebooks in my research group. But, it is difficult to refer (when in a phone meeting) to specific figures or pieces of code or other output in the notebook. This is because the cells are often executed out of order, so they have non-sequential numbers. Now, in some situations, knowing the order of execution is crucial. But usually in this case, the order is unimportant. The non-sequential ordering is due to things like "oh, I made a mistake in the fifth figure, let me try a few things to fix it, now the 4th figure needs to be fixed too," etc. So, if it were possible to re-number the cells, either in the notebook proper or in the nbconvert step, that would make our lives a little bit easier. Alternatively, it would be pretty awesome if figures could have automatic (sequential) figure numbering. Then the cell numbering wouldn't matter nearly as much. Regards, Jon From takowl at gmail.com Thu Sep 18 17:30:52 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Thu, 18 Sep 2014 14:30:52 -0700 Subject: [IPython-dev] Renumber cells for nbconvert In-Reply-To: <541B4A32.20204@fnal.gov> References: <541B4A32.20204@fnal.gov> Message-ID: Hi Jon, The simplest thing would be to use the ExecutePreprocessor available now in master to run the notebooks in order before converting them. That both puts the numbers in order and keeps them corresponding to the order of execution. Thomas On 18 September 2014 14:10, Jon Wilson wrote: > Hi, > We often share around nbconverted notebooks in my research group. But, > it is difficult to refer (when in a phone meeting) to specific figures > or pieces of code or other output in the notebook. This is because the > cells are often executed out of order, so they have non-sequential numbers. > > Now, in some situations, knowing the order of execution is crucial. > But usually in this case, the order is unimportant. The non-sequential > ordering is due to things like "oh, I made a mistake in the fifth > figure, let me try a few things to fix it, now the 4th figure needs to > be fixed too," etc. > > So, if it were possible to re-number the cells, either in the notebook > proper or in the nbconvert step, that would make our lives a little bit > easier. > > Alternatively, it would be pretty awesome if figures could have > automatic (sequential) figure numbering. Then the cell numbering > wouldn't matter nearly as much. > Regards, > Jon > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: From jsw at fnal.gov Thu Sep 18 17:36:12 2014 From: jsw at fnal.gov (Jon Wilson) Date: Thu, 18 Sep 2014 16:36:12 -0500 Subject: [IPython-dev] Renumber cells for nbconvert In-Reply-To: References: <541B4A32.20204@fnal.gov> Message-ID: <541B504C.5050000@fnal.gov> Hi Thomas, That sounds great, but some of our notebooks can take hours or even days to execute, so I don't think that this is an option. The notebook that prompted this email, according to the student whose notebook it is, takes 20-30 minutes to run. Of course, some take less than a minute, and this solution is perfect for those short-run notebooks. Regards, Jon On 09/18/2014 04:30 PM, Thomas Kluyver wrote: > Hi Jon, > > The simplest thing would be to use the ExecutePreprocessor available > now in master to run the notebooks in order before converting them. > That both puts the numbers in order and keeps them corresponding to > the order of execution. > > Thomas > > On 18 September 2014 14:10, Jon Wilson > wrote: > > Hi, > We often share around nbconverted notebooks in my research group. But, > it is difficult to refer (when in a phone meeting) to specific figures > or pieces of code or other output in the notebook. This is > because the > cells are often executed out of order, so they have non-sequential > numbers. > > Now, in some situations, knowing the order of execution is crucial. > But usually in this case, the order is unimportant. The > non-sequential > ordering is due to things like "oh, I made a mistake in the fifth > figure, let me try a few things to fix it, now the 4th figure needs to > be fixed too," etc. > > So, if it were possible to re-number the cells, either in the notebook > proper or in the nbconvert step, that would make our lives a > little bit > easier. > > Alternatively, it would be pretty awesome if figures could have > automatic (sequential) figure numbering. Then the cell numbering > wouldn't matter nearly as much. > Regards, > Jon > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: From takowl at gmail.com Thu Sep 18 17:41:51 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Thu, 18 Sep 2014 14:41:51 -0700 Subject: [IPython-dev] Renumber cells for nbconvert In-Reply-To: <541B504C.5050000@fnal.gov> References: <541B4A32.20204@fnal.gov> <541B504C.5050000@fnal.gov> Message-ID: On 18 September 2014 14:36, Jon Wilson wrote: > That sounds great, but some of our notebooks can take hours or even days > to execute, so I don't think that this is an option. The notebook that > prompted this email, according to the student whose notebook it is, takes > 20-30 minutes to run. I had a feeling you were going to say that. ;-) It should be fairly straightforward to build an extension that renumbers cells without running them, but I'd rather not promote that, because it breaks the model of cell numbers representing execution order. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: From jsw at fnal.gov Thu Sep 18 17:44:21 2014 From: jsw at fnal.gov (Jon Wilson) Date: Thu, 18 Sep 2014 16:44:21 -0500 Subject: [IPython-dev] Renumber cells for nbconvert In-Reply-To: References: <541B4A32.20204@fnal.gov> <541B504C.5050000@fnal.gov> Message-ID: <541B5235.9020701@fnal.gov> Hi Thomas, Yes, it does break that, which is unfortunate. What about automatic figure numbering? Of course, the low-tech solution is to tell everyone that they have to make sequentially-numbered section headings or something similar. Regards, Jon On 09/18/2014 04:41 PM, Thomas Kluyver wrote: > On 18 September 2014 14:36, Jon Wilson > wrote: > > That sounds great, but some of our notebooks can take hours or > even days to execute, so I don't think that this is an option. > The notebook that prompted this email, according to the student > whose notebook it is, takes 20-30 minutes to run. > > > I had a feeling you were going to say that. ;-) It should be fairly > straightforward to build an extension that renumbers cells without > running them, but I'd rather not promote that, because it breaks the > model of cell numbers representing execution order. > > Thomas > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: From takowl at gmail.com Thu Sep 18 17:46:44 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Thu, 18 Sep 2014 14:46:44 -0700 Subject: [IPython-dev] Renumber cells for nbconvert In-Reply-To: <541B5235.9020701@fnal.gov> References: <541B4A32.20204@fnal.gov> <541B504C.5050000@fnal.gov> <541B5235.9020701@fnal.gov> Message-ID: On 18 September 2014 14:44, Jon Wilson wrote: > Yes, it does break that, which is unfortunate. What about automatic > figure numbering? > That's also possible, especially if you can put up with something not especially aesthetic - walk through the cells and outputs, find each png, and insert a text output below it with "Figure x". Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: From jsw at fnal.gov Thu Sep 18 17:49:02 2014 From: jsw at fnal.gov (Jon Wilson) Date: Thu, 18 Sep 2014 16:49:02 -0500 Subject: [IPython-dev] Renumber cells for nbconvert In-Reply-To: References: <541B4A32.20204@fnal.gov> <541B504C.5050000@fnal.gov> <541B5235.9020701@fnal.gov> Message-ID: <541B534E.1070305@fnal.gov> Hi Thomas, Thanks! I will look into doing that. Regards, Jon On 09/18/2014 04:46 PM, Thomas Kluyver wrote: > On 18 September 2014 14:44, Jon Wilson > wrote: > > Yes, it does break that, which is unfortunate. What about > automatic figure numbering? > > > That's also possible, especially if you can put up with something not > especially aesthetic - walk through the cells and outputs, find each > png, and insert a text output below it with "Figure x". > > Thomas > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: From doug.blank at gmail.com Thu Sep 18 17:55:35 2014 From: doug.blank at gmail.com (Doug Blank) Date: Thu, 18 Sep 2014 17:55:35 -0400 Subject: [IPython-dev] Renumber cells for nbconvert In-Reply-To: <541B5235.9020701@fnal.gov> References: <541B4A32.20204@fnal.gov> <541B504C.5050000@fnal.gov> <541B5235.9020701@fnal.gov> Message-ID: On Thu, Sep 18, 2014 at 5:44 PM, Jon Wilson wrote: > Hi Thomas, > Yes, it does break that, which is unfortunate. > I was thinking about adding a "Force cell renumbering" option in our Calico Document Tools extension for another reason: in class, I sometimes want to clear the output, but still have the numbers for reference. Unfortunately, the "clear all output" clears the cell numbers too. This would be trivial code, but like Thomas mentioned, it destroys the sequence of operation. Although, I just tested the ability to renumber cells using a different scheme, such as "A", "B", "C", ... or "I", "II", "III" (or some other pattern) and that appears to work. Renumbering using a different numbering scheme could show the order, but also indicate that this isn't operation order. > What about automatic figure numbering? > Do you have a standard method of referring to figures? We have a bibliography tool, and so a Figure Renumbering Tool would fit right in with that. > Of course, the low-tech solution is to tell everyone that they have to > make sequentially-numbered section headings or something similar. > We have a Heading Numbering Tool in the collection (and ways to move sections) that you might like. See: http://calicoproject.org/ICalico#Calico_Notebook_Extensions -Doug > Regards, > Jon > > > On 09/18/2014 04:41 PM, Thomas Kluyver wrote: > > On 18 September 2014 14:36, Jon Wilson wrote: > >> That sounds great, but some of our notebooks can take hours or even days >> to execute, so I don't think that this is an option. The notebook that >> prompted this email, according to the student whose notebook it is, takes >> 20-30 minutes to run. > > > I had a feeling you were going to say that. ;-) It should be fairly > straightforward to build an extension that renumbers cells without running > them, but I'd rather not promote that, because it breaks the model of cell > numbers representing execution order. > > Thomas > > > _______________________________________________ > IPython-dev mailing listIPython-dev at scipy.orghttp://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From takowl at gmail.com Thu Sep 18 17:59:25 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Thu, 18 Sep 2014 14:59:25 -0700 Subject: [IPython-dev] Renumber cells for nbconvert In-Reply-To: References: <541B4A32.20204@fnal.gov> <541B504C.5050000@fnal.gov> <541B5235.9020701@fnal.gov> Message-ID: On 18 September 2014 14:55, Doug Blank wrote: > Although, I just tested the ability to renumber cells using a different > scheme, such as "A", "B", "C", ... or "I", "II", "III" (or some other > pattern) and that appears to work. Renumbering using a different numbering > scheme could show the order, but also indicate that this isn't operation > order. Fair warning: if you do this and save the resulting notebook structure, we consider that an invalid notebook, since prompt numbers should be integers or null. Just doing it for static rendering might be OK, though. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: From doug.blank at gmail.com Thu Sep 18 18:12:33 2014 From: doug.blank at gmail.com (Doug Blank) Date: Thu, 18 Sep 2014 18:12:33 -0400 Subject: [IPython-dev] Renumber cells for nbconvert In-Reply-To: References: <541B4A32.20204@fnal.gov> <541B504C.5050000@fnal.gov> <541B5235.9020701@fnal.gov> Message-ID: On Thu, Sep 18, 2014 at 5:59 PM, Thomas Kluyver wrote: > On 18 September 2014 14:55, Doug Blank wrote: > >> Although, I just tested the ability to renumber cells using a different >> scheme, such as "A", "B", "C", ... or "I", "II", "III" (or some other >> pattern) and that appears to work. Renumbering using a different numbering >> scheme could show the order, but also indicate that this isn't operation >> order. > > > Fair warning: if you do this and save the resulting notebook structure, we > consider that an invalid notebook, since prompt numbers should be integers > or null. Just doing it for static rendering might be OK, though. > Fair enough :) But, I did some more experimenting on master and found that floating-point numbers seem to pass as valid (eg, it at least saves and loads). But you are right that "A" gets reset to null on load. (Note that I'm not necessarily actually advocating this kind of numbering, just experimenting and attempting to show this difference (execution order vs. reference order). Thinking outside the box, er, cell, as it were. -Doug > > > Thomas > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From doug.blank at gmail.com Thu Sep 18 18:41:22 2014 From: doug.blank at gmail.com (Doug Blank) Date: Thu, 18 Sep 2014 18:41:22 -0400 Subject: [IPython-dev] Renumber cells for nbconvert In-Reply-To: <541B5235.9020701@fnal.gov> References: <541B4A32.20204@fnal.gov> <541B504C.5050000@fnal.gov> <541B5235.9020701@fnal.gov> Message-ID: On Thu, Sep 18, 2014 at 5:44 PM, Jon Wilson wrote: > Hi Thomas, > Yes, it does break that, which is unfortunate. > Jon, further reflection in the forced renumbering of cells (even when clearing output) seems like a Really Bad Idea.... it is mucking around with the reproducibility of the notebook---sorta like photoshopping a model to make them like they don't. But, what about an automatic *labelling* of cells? I'm thinking about a tool that could add a markdown cell above each code cell that could label it, like the attached picture. > What about automatic figure numbering? > Then we can treat code cells like figures, and renumber both, for reference purposes. -Doug > > Of course, the low-tech solution is to tell everyone that they have to > make sequentially-numbered section headings or something similar. > Regards, > Jon > > > On 09/18/2014 04:41 PM, Thomas Kluyver wrote: > > On 18 September 2014 14:36, Jon Wilson wrote: > >> That sounds great, but some of our notebooks can take hours or even days >> to execute, so I don't think that this is an option. The notebook that >> prompted this email, according to the student whose notebook it is, takes >> 20-30 minutes to run. > > > I had a feeling you were going to say that. ;-) It should be fairly > straightforward to build an extension that renumbers cells without running > them, but I'd rather not promote that, because it breaks the model of cell > numbers representing execution order. > > Thomas > > > _______________________________________________ > IPython-dev mailing listIPython-dev at scipy.orghttp://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: Screenshot from 2014-09-18 18:35:23.png Type: image/png Size: 40496 bytes Desc: not available URL: From hughesadam87 at gmail.com Thu Sep 18 19:22:49 2014 From: hughesadam87 at gmail.com (Adam Hughes) Date: Thu, 18 Sep 2014 19:22:49 -0400 Subject: [IPython-dev] Possible issues with submodule updates In-Reply-To: References: Message-ID: Yes, it turns out that her problem was the cache. Thanks! On Tue, Sep 16, 2014 at 2:58 PM, Adam Hughes wrote: > Ok thanks for the help. > > So you guys haven't had any issues installing this onto mac and running on > chome I take it? Still odd that my colleague is getting hung up. > > On Tue, Sep 16, 2014 at 2:47 PM, Fernando Perez > wrote: > >> also, super useful (for Chrome users): >> https://chrome.google.com/webstore/detail/clear-cache/cppjkneekbjaeellbfkmgnhonkkjfpdn?hl=en >> >> On Tue, Sep 16, 2014 at 11:44 AM, Thomas Kluyver >> wrote: >> >>> We have a lot of issues with browsers caching Javascript files. Min's >>> working on a better solution to this, but in the meantime, try clearing the >>> cache as much as possible. Sometimes starting the browser in private mode >>> seems to get round caching issues. >>> >>> Thomas >>> >>> On 16 September 2014 11:35, Adam Hughes wrote: >>> >>>> Also, my student is still having her mac freeze out. We reinstalled on >>>> her computer, restarted, checked that the git submodule status was the >>>> same, and she's still getting frozen cells each time. >>>> >>>> On Tue, Sep 16, 2014 at 2:28 PM, Adam Hughes >>>> wrote: >>>> >>>>> Just a quick update. >>>>> >>>>> I was able to get 3.0.0 working. Interestingly, when I update from >>>>> 2-->3, my chrome browser gets hung up. That's what happened originally, so >>>>> it is the installation that does something to the browser. Restarting the >>>>> computer gets rid of it. Not sure if this is just a chrome issue. >>>>> >>>>> Thanks >>>>> >>>>> On Tue, Sep 16, 2014 at 2:09 PM, Adam Hughes >>>>> wrote: >>>>> >>>>>> Hey Min, >>>>>> >>>>>> This was some weird browser error. I hadn't thought to reboot my >>>>>> system, but indeed it was something with my system. Sorry for being too >>>>>> dense to think to try this first! >>>>>> >>>>>> On Tue, Sep 16, 2014 at 2:02 PM, Adam Hughes >>>>>> wrote: >>>>>> >>>>>>> # On branch 2.x >>>>>>> # Your branch is up-to-date with 'origin/2.x'. >>>>>>> # >>>>>>> # Untracked files: >>>>>>> # (use "git add ..." to include in what will be committed) >>>>>>> # >>>>>>> # Untitled0.ipynb >>>>>>> # Untitled1.ipynb >>>>>>> # Untitled2.ipynb >>>>>>> # Untitled3.ipynb >>>>>>> # >>>>>>> nothing added to commit but untracked files present (use "git add" >>>>>>> to track) >>>>>>> glue at glue-desktop:~/ipython$ git submodule status >>>>>>> 47ed6b9e18670a0d653d99e97e6165c14dd14047 >>>>>>> IPython/html/static/components (2.1.0) >>>>>>> glue at glue-desktop:~/ipython$ >>>>>>> >>>>>>> >>>>>>> On Tue, Sep 16, 2014 at 1:55 PM, MinRK wrote: >>>>>>> >>>>>>>> What do you get from git status and git submodule status? >>>>>>>> ? >>>>>>>> >>>>>>>> On Tue, Sep 16, 2014 at 10:43 AM, Adam Hughes < >>>>>>>> hughesadam87 at gmail.com> wrote: >>>>>>>> >>>>>>>>> Hi, >>>>>>>>> >>>>>>>>> I just updated to the new dev version, and ran python setup.py >>>>>>>>> submodule as usual, then setup.py install. When I open a notebook, either >>>>>>>>> new or pre-made, I get a blank window. I get this error: >>>>>>>>> >>>>>>>>> WARNING:tornado.access:404 GET /static/jqueryui.js (127.0.0.1) >>>>>>>>> 0.72ms referer=http://localhost:8890/notebooks/Untitled0.ipynb >>>>>>>>> >>>>>>>>> I've updated tornado, and nothing happens. I've reverted back to >>>>>>>>> ipython 2.3 and I still get this. I'm on ubuntu. >>>>>>>>> >>>>>>>>> My friend is using mac osx 10.7. Her notebook actually loadas, >>>>>>>>> but runs her first cell, regardless of what's in it, the kernel freezes. >>>>>>>>> IE the cell's indicator changes to a " * " and stays like that. >>>>>>>>> >>>>>>>>> Is anyone else experiences such issues? >>>>>>>>> >>>>>>>>> Here is my pip freeze output (note pip freeze still says on on >>>>>>>>> ipython 3.0, but if I run ipython in the terminal, it starts as 2.3: >>>>>>>>> >>>>>>>>> Canopy==1.4.0.dev6600 >>>>>>>>> Cython==0.21 >>>>>>>>> Examples==7.3 >>>>>>>>> Flask==0.10.1 >>>>>>>>> Jinja2==2.7.3 >>>>>>>>> MKL==10.3 >>>>>>>>> Markdown==2.4.1 >>>>>>>>> MarkupSafe==0.23 >>>>>>>>> PIL==1.1.7 >>>>>>>>> PySide==1.2.1 >>>>>>>>> PyYAML==3.11 >>>>>>>>> Pygments==1.6.0 >>>>>>>>> PythonDoc==2.7.3 >>>>>>>>> Qt==4.8.5 >>>>>>>>> Shapely==1.3.2 >>>>>>>>> VTK==5.10.1 >>>>>>>>> Werkzeug==0.9.6 >>>>>>>>> appinst==2.1.2 >>>>>>>>> apptools==4.2.1 >>>>>>>>> atom==0.3.9 >>>>>>>>> backports.ssl-match-hostname==3.4.0.2 >>>>>>>>> basemap==1.0.7 >>>>>>>>> bokeh==0.5.2 >>>>>>>>> casuarius==1.1 >>>>>>>>> certifi==14.05.14 >>>>>>>>> chaco==4.4.1 >>>>>>>>> cloud==2.4.6 >>>>>>>>> colorama==0.3.1 >>>>>>>>> configobj==5.0.6 >>>>>>>>> coverage==3.7.1 >>>>>>>>> docutils==0.11 >>>>>>>>> enable==4.4.1 >>>>>>>>> enaml==0.9.5 >>>>>>>>> encore==0.5.1 >>>>>>>>> enstaller==4.6.5 >>>>>>>>> envisage==4.4.0 >>>>>>>>> esky==0.9.8dev >>>>>>>>> etsproxy==0.1.2 >>>>>>>>> faulthandler==2.2 >>>>>>>>> feedparser==5.1.3 >>>>>>>>> freetype==2.5.3 >>>>>>>>> geopandas==0.1.0.dev-35c2f5b >>>>>>>>> gevent==1.0.1 >>>>>>>>> gevent-websocket==0.9.3 >>>>>>>>> glib==2.36.1 >>>>>>>>> gnureadline==6.2.5 >>>>>>>>> greenlet==0.4.3 >>>>>>>>> grits-client==0.1 >>>>>>>>> gst-plugins-bad==0.10.23 >>>>>>>>> gst-plugins-base==0.10.36 >>>>>>>>> gst-plugins-good==0.10.30 >>>>>>>>> gstreamer==0.10.36 >>>>>>>>> idle==2.7.3 >>>>>>>>> ipython==3.0.0-dev >>>>>>>>> itsdangerous==0.24 >>>>>>>>> jdcal==1.0 >>>>>>>>> jsonpickle==0.4.0 >>>>>>>>> jsonpointer==1.4 >>>>>>>>> jsonschema==2.3.0 >>>>>>>>> kernmagic==0.2.0 >>>>>>>>> keyring==3.6dev >>>>>>>>> kiwisolver==0.1.2 >>>>>>>>> libffi==3.0.13 >>>>>>>>> libgfortran==3.0.0 >>>>>>>>> libjpeg==7.0 >>>>>>>>> libjpeg62==6.2 >>>>>>>>> libncurses==5.9 >>>>>>>>> libogg==1.3.0 >>>>>>>>> libpng==1.6.12 >>>>>>>>> libtheora==1.1.1 >>>>>>>>> libvpx==1.1.0 >>>>>>>>> libxml2==2.7.8 >>>>>>>>> matplotlib==1.4.0 >>>>>>>>> mayavi==4.3.1 >>>>>>>>> mock==1.0.1 >>>>>>>>> nbopen==0.1 >>>>>>>>> nmrglue==0.4 >>>>>>>>> nose==1.3.3 >>>>>>>>> numpy==1.8.2 >>>>>>>>> openpyxl==2.0.3 >>>>>>>>> pandas==0.14.0 >>>>>>>>> patsy==0.2.1 >>>>>>>>> plotly==1.1.4 >>>>>>>>> ply==3.4 >>>>>>>>> psutil==1.2.1 >>>>>>>>> pyaudio==0.2.4 >>>>>>>>> pyface==4.4.0 >>>>>>>>> pyflakes==0.7.3 >>>>>>>>> pyglet==1.1.4 >>>>>>>>> pyparsing==2.0.2 >>>>>>>>> -e git+ >>>>>>>>> https://github.com/hugadams/pyparty.git at e719a2c21d0e9ee32d36347792572bd61571de21#egg=pyparty-master >>>>>>>>> pyproj==1.9.3 >>>>>>>>> pysdmx==0.1 >>>>>>>>> pystache==0.5.4 >>>>>>>>> python-dateutil==2.2.0 >>>>>>>>> pytz==2013b >>>>>>>>> -e git+ >>>>>>>>> https://github.com/hugadams/pyuvvis.git at a40befc64b0ac8a18d344d0e40b32b2b68dc3128#egg=pyuvvis-master >>>>>>>>> pyzmq==14.3.1 >>>>>>>>> readline==6.2.4.1 >>>>>>>>> redis==2.10.3 >>>>>>>>> requests==2.2.1 >>>>>>>>> restview==2.0.5 >>>>>>>>> runipy==0.1.0 >>>>>>>>> scikit-learn==0.14.1 >>>>>>>>> scikits.image==0.9.3 >>>>>>>>> scipy==0.14.0 >>>>>>>>> shiboken==1.2.1 >>>>>>>>> six==1.7.3 >>>>>>>>> ssl-match-hostname==3.4.0.2 >>>>>>>>> statsmodels==0.5.0 >>>>>>>>> supplement==0.5dev.dev202 >>>>>>>>> svgwrite==1.1.2 >>>>>>>>> sympy==0.7.5 >>>>>>>>> tornado==4.0.2 >>>>>>>>> traits==4.5.0 >>>>>>>>> traitsui==4.4.0 >>>>>>>>> websocket==0.2.1 >>>>>>>>> wsgiref==0.1.2 >>>>>>>>> wxPython==2.8.10.1 >>>>>>>>> xray==0.1.1 >>>>>>>>> zeromq==4.0.4 >>>>>>>>> zlib==1.2.6 >>>>>>>>> >>>>>>>>> >>>>>>>>> >>>>>>>>> _______________________________________________ >>>>>>>>> IPython-dev mailing list >>>>>>>>> IPython-dev at scipy.org >>>>>>>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>>>>>>> >>>>>>>>> >>>>>>>> >>>>>>>> _______________________________________________ >>>>>>>> IPython-dev mailing list >>>>>>>> IPython-dev at scipy.org >>>>>>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>>>>>> >>>>>>>> >>>>>>> >>>>>> >>>>> >>>> >>>> _______________________________________________ >>>> IPython-dev mailing list >>>> IPython-dev at scipy.org >>>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>>> >>>> >>> >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >>> >>> >> >> >> -- >> Fernando Perez (@fperez_org; http://fperez.org) >> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) >> fernando.perez-at-berkeley: contact me here for any direct mail >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > -------------- next part -------------- An HTML attachment was scrubbed... URL: From nathan12343 at gmail.com Thu Sep 18 20:14:25 2014 From: nathan12343 at gmail.com (Nathan Goldbaum) Date: Thu, 18 Sep 2014 17:14:25 -0700 Subject: [IPython-dev] Current status of sharing/publishing widgets? Message-ID: Hi all, I've recently been spending some time creating a widget that I'd ideally like to publish along with a paper submission to the arxiv. This would hopefully just be a link that readers could click on that would take them to a page where they can explore the widget without having to run the code or have all the data necessary to generate the widget from script. I know that there were plans to get something like this working for IPython 3.0. What is the current status? Is it possible to share widgets on e.g. nbviewer? Failing that, what are the current best practices for sharing widgets? -Nathan -------------- next part -------------- An HTML attachment was scrubbed... URL: From jsw at fnal.gov Thu Sep 18 21:08:03 2014 From: jsw at fnal.gov (Jon Wilson) Date: Thu, 18 Sep 2014 20:08:03 -0500 Subject: [IPython-dev] Renumber cells for nbconvert In-Reply-To: References: <541B4A32.20204@fnal.gov> <541B504C.5050000@fnal.gov> <541B5235.9020701@fnal.gov> Message-ID: <541B81F3.6090704@fnal.gov> On 09/18/2014 05:41 PM, Doug Blank wrote: > On Thu, Sep 18, 2014 at 5:44 PM, Jon Wilson > wrote: > > Hi Thomas, > Yes, it does break that, which is unfortunate. > > > Jon, further reflection in the forced renumbering of cells (even when > clearing output) seems like a Really Bad Idea.... it is mucking around > with the reproducibility of the notebook---sorta like photoshopping a > model to make them like they don't. But, what about an automatic > *labelling* of cells? I'm thinking about a tool that could add a > markdown cell above each code cell that could label it, like the > attached picture. Hi Doug, I like the attached screenshot, but I'd want to muck around with the CSS a bit. The positioning of the cell numbers off the to left makes them a draw for the eye when you're looking for index-like information. I think that de-emphasizing those numbers and moving the sequential cell numbers off to the left would be good. But, the most important thing is to be able to find what the presenter is talking about, and this already accomplishes that. Regarding reproducibility, renumbering the cells might actually improve it in some cases. If I've been working on a notebook for a while, I sometimes have executed and re-executed various cells so many times that, if you executed the cells in the order listed, you would use things before they were defined. Example: define a variable, then make two figures. Then edit the variable definition, re-run it, re-run one of the figures, then change it back and run that figure again. Now, the order of the cell numbering is figure 1, definition, figure 2. If you ran the cells in that order, it would raise an exception on figure 1. If you re-numbered the cells, then you would run the cells as definition, figure 1, figure 2, and everything would be fine. Of course, all that is just sloppy discipline on my part and an argument for periodically restarting the kernel and running everything from the beginning. But sometimes that is too expensive to do. > > What about automatic figure numbering? > > > Then we can treat code cells like figures, and renumber both, for > reference purposes. I like it. The only thing I would change is that I would not number every code cell. When we're talking about notebooks, we're only very rarely talking about the code itself. Instead, plots and tables and numbers are the most important things. So if I had my "druthers", only cells that produce meaningful output would be numbered. Thanks for all the great ideas, guys! Regards, Jon -------------- next part -------------- An HTML attachment was scrubbed... URL: From nathan12343 at gmail.com Thu Sep 18 21:14:22 2014 From: nathan12343 at gmail.com (Nathan Goldbaum) Date: Thu, 18 Sep 2014 18:14:22 -0700 Subject: [IPython-dev] Renumber cells for nbconvert In-Reply-To: <541B81F3.6090704@fnal.gov> References: <541B4A32.20204@fnal.gov> <541B504C.5050000@fnal.gov> <541B5235.9020701@fnal.gov> <541B81F3.6090704@fnal.gov> Message-ID: On Thu, Sep 18, 2014 at 6:08 PM, Jon Wilson wrote: > > On 09/18/2014 05:41 PM, Doug Blank wrote: > > On Thu, Sep 18, 2014 at 5:44 PM, Jon Wilson wrote: > >> Hi Thomas, >> Yes, it does break that, which is unfortunate. >> > > Jon, further reflection in the forced renumbering of cells (even when > clearing output) seems like a Really Bad Idea.... it is mucking around with > the reproducibility of the notebook---sorta like photoshopping a model to > make them like they don't. But, what about an automatic *labelling* of > cells? I'm thinking about a tool that could add a markdown cell above each > code cell that could label it, like the attached picture. > > > Hi Doug, > I like the attached screenshot, but I'd want to muck around with the CSS a > bit. The positioning of the cell numbers off the to left makes them a draw > for the eye when you're looking for index-like information. I think that > de-emphasizing those numbers and moving the sequential cell numbers off to > the left would be good. But, the most important thing is to be able to > find what the presenter is talking about, and this already accomplishes > that. > > Regarding reproducibility, renumbering the cells might actually improve it > in some cases. If I've been working on a notebook for a while, I sometimes > have executed and re-executed various cells so many times that, if you > executed the cells in the order listed, you would use things before they > were defined. Example: define a variable, then make two figures. Then > edit the variable definition, re-run it, re-run one of the figures, then > change it back and run that figure again. Now, the order of the cell > numbering is figure 1, definition, figure 2. If you ran the cells in that > order, it would raise an exception on figure 1. If you re-numbered the > cells, then you would run the cells as definition, figure 1, figure 2, and > everything would be fine. Of course, all that is just sloppy discipline on > my part and an argument for periodically restarting the kernel and running > everything from the beginning. But sometimes that is too expensive to do. > Using a memoization patterns can be very useful for quickly regenerating the results of a long-running computation (although that comes with all issues inherent in caching data and adding state to your notebook, so buyer beware). I've had some success with joblib [0] in the past to manage caching. One nice feature is it takes a cryptographic hash of numpy arrays that are provided as input to a function, so it's able to efficiently determine whether a function you want to memoize has had as input in the past some arbitrarily filled out numpy array, making it very straightforward to memoize functions that have numpy arrays as input. [0] https://pythonhosted.org/joblib/ -Nathan > > What about automatic figure numbering? >> > > Then we can treat code cells like figures, and renumber both, for > reference purposes. > > I like it. The only thing I would change is that I would not number every > code cell. When we're talking about notebooks, we're only very rarely > talking about the code itself. Instead, plots and tables and numbers are > the most important things. So if I had my "druthers", only cells that > produce meaningful output would be numbered. > > Thanks for all the great ideas, guys! > Regards, > Jon > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From sylvain.corlay at gmail.com Thu Sep 18 22:41:50 2014 From: sylvain.corlay at gmail.com (Sylvain Corlay) Date: Thu, 18 Sep 2014 22:41:50 -0400 Subject: [IPython-dev] Renumber cells for nbconvert In-Reply-To: References: <541B4A32.20204@fnal.gov> <541B504C.5050000@fnal.gov> <541B5235.9020701@fnal.gov> <541B81F3.6090704@fnal.gov> Message-ID: Forcing renumbering in nbconvert would still be useful when converting to script. Spyder for example has an "outline explorer" that gathers all the cell separators in a Python file, since 2.3, (# In[*], # and # %%), possibly generated from nbconvert. In this context, it would make more sense to use the natural ordering than the execution order of the notebook. S. On Thu, Sep 18, 2014 at 9:14 PM, Nathan Goldbaum wrote: > > > On Thu, Sep 18, 2014 at 6:08 PM, Jon Wilson wrote: >> >> >> On 09/18/2014 05:41 PM, Doug Blank wrote: >> >> On Thu, Sep 18, 2014 at 5:44 PM, Jon Wilson wrote: >>> >>> Hi Thomas, >>> Yes, it does break that, which is unfortunate. >> >> >> Jon, further reflection in the forced renumbering of cells (even when >> clearing output) seems like a Really Bad Idea.... it is mucking around with >> the reproducibility of the notebook---sorta like photoshopping a model to >> make them like they don't. But, what about an automatic *labelling* of >> cells? I'm thinking about a tool that could add a markdown cell above each >> code cell that could label it, like the attached picture. >> >> >> Hi Doug, >> I like the attached screenshot, but I'd want to muck around with the CSS a >> bit. The positioning of the cell numbers off the to left makes them a draw >> for the eye when you're looking for index-like information. I think that >> de-emphasizing those numbers and moving the sequential cell numbers off to >> the left would be good. But, the most important thing is to be able to find >> what the presenter is talking about, and this already accomplishes that. >> >> Regarding reproducibility, renumbering the cells might actually improve it >> in some cases. If I've been working on a notebook for a while, I sometimes >> have executed and re-executed various cells so many times that, if you >> executed the cells in the order listed, you would use things before they >> were defined. Example: define a variable, then make two figures. Then edit >> the variable definition, re-run it, re-run one of the figures, then change >> it back and run that figure again. Now, the order of the cell numbering is >> figure 1, definition, figure 2. If you ran the cells in that order, it >> would raise an exception on figure 1. If you re-numbered the cells, then >> you would run the cells as definition, figure 1, figure 2, and everything >> would be fine. Of course, all that is just sloppy discipline on my part and >> an argument for periodically restarting the kernel and running everything >> from the beginning. But sometimes that is too expensive to do. > > > Using a memoization patterns can be very useful for quickly regenerating the > results of a long-running computation (although that comes with all issues > inherent in caching data and adding state to your notebook, so buyer > beware). > > I've had some success with joblib [0] in the past to manage caching. One > nice feature is it takes a cryptographic hash of numpy arrays that are > provided as input to a function, so it's able to efficiently determine > whether a function you want to memoize has had as input in the past some > arbitrarily filled out numpy array, making it very straightforward to > memoize functions that have numpy arrays as input. > > [0] https://pythonhosted.org/joblib/ > > -Nathan > >> >> >>> What about automatic figure numbering? >> >> >> Then we can treat code cells like figures, and renumber both, for >> reference purposes. >> >> I like it. The only thing I would change is that I would not number every >> code cell. When we're talking about notebooks, we're only very rarely >> talking about the code itself. Instead, plots and tables and numbers are >> the most important things. So if I had my "druthers", only cells that >> produce meaningful output would be numbered. >> >> Thanks for all the great ideas, guys! >> Regards, >> Jon >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > From bussonniermatthias at gmail.com Fri Sep 19 04:18:44 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Fri, 19 Sep 2014 10:18:44 +0200 Subject: [IPython-dev] Current status of sharing/publishing widgets? In-Reply-To: References: Message-ID: Hi, No it cannot be shared currently on nbviewer. What I would suggest is building a single-cell app that feed the widget with precomputed data depending on the possibilities. It could be hosted on a Heroku-like platform but still require some extra work. Otherwise you have to ask people to download your lib and run it. -- M Envoy? de mon iPhone > Le 19 sept. 2014 ? 02:14, Nathan Goldbaum a ?crit : > > Hi all, > > I've recently been spending some time creating a widget that I'd ideally like to publish along with a paper submission to the arxiv. This would hopefully just be a link that readers could click on that would take them to a page where they can explore the widget without having to run the code or have all the data necessary to generate the widget from script. > > I know that there were plans to get something like this working for IPython 3.0. > > What is the current status? Is it possible to share widgets on e.g. nbviewer? Failing that, what are the current best practices for sharing widgets? > > -Nathan > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From jason-sage at creativetrax.com Fri Sep 19 08:24:08 2014 From: jason-sage at creativetrax.com (Jason Grout) Date: Fri, 19 Sep 2014 08:24:08 -0400 Subject: [IPython-dev] Current status of sharing/publishing widgets? In-Reply-To: References: Message-ID: <541C2068.8000204@creativetrax.com> On 9/19/14, 4:18, Matthias Bussonnier wrote: > Hi, > No it cannot be shared currently on nbviewer. What I would suggest is building a single-cell app that feed the widget with precomputed data depending on the possibilities. It could be hosted on a Heroku-like platform but still require some extra work. > > Otherwise you have to ask people to download your lib and run it. > The Sage Cell server is a hosted web app you can embed in any page (or link to directly), and it supports IPython widgets: https://sagecell.sagemath.org (see the About page for more details, or email the sage-cell mailing list for help: https://groups.google.com/forum/#!forum/sage-cell) Jason From pelson.pub at gmail.com Fri Sep 19 11:55:53 2014 From: pelson.pub at gmail.com (Phil Elson) Date: Fri, 19 Sep 2014 16:55:53 +0100 Subject: [IPython-dev] Notebook: Retaining mouse events when destroying elements with JS Message-ID: I've got a case where I'm implementing a button which removes some output via JS when clicked. The removal is working as expected, but IPython's keyboard events are no longer firing after the button has been clicked. Essentially I have a single cell with the following: from IPython.display import HTML HTML(""" """) This is part of a more complex system which cannot currently make use of the widget infrastructure, so wonder if anybody can give me any clues as to how to prevent the IPython keyboard short-cuts from disappearing once the button is pressed? Thanks! Phil -------------- next part -------------- An HTML attachment was scrubbed... URL: From takowl at gmail.com Fri Sep 19 13:54:59 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Fri, 19 Sep 2014 10:54:59 -0700 Subject: [IPython-dev] Current status of sharing/publishing widgets? In-Reply-To: References: Message-ID: It's worth mentioning that we have plans to make this use case easier. There are three things we're planning to do: - Store widgets in the notebook document format, so they persist in a notebook without having to rerun the cells generating them. - Make a 'comms only kernel' that handles widget requests but not regular execution messages, so you can expose it on the public internet (relatively) safely. - Make a tool that can iterate through all possible widget states and record the output to a set of small files, so you can run simple widget-driven things from a static file server. Thomas On 19 September 2014 01:18, Matthias Bussonnier < bussonniermatthias at gmail.com> wrote: > Hi, > No it cannot be shared currently on nbviewer. What I would suggest is > building a single-cell app that feed the widget with precomputed data > depending on the possibilities. It could be hosted on a Heroku-like > platform but still require some extra work. > > Otherwise you have to ask people to download your lib and run it. > -- > M > > > Envoy? de mon iPhone > > > Le 19 sept. 2014 ? 02:14, Nathan Goldbaum a > ?crit : > > > > Hi all, > > > > I've recently been spending some time creating a widget that I'd ideally > like to publish along with a paper submission to the arxiv. This would > hopefully just be a link that readers could click on that would take them > to a page where they can explore the widget without having to run the code > or have all the data necessary to generate the widget from script. > > > > I know that there were plans to get something like this working for > IPython 3.0. > > > > What is the current status? Is it possible to share widgets on e.g. > nbviewer? Failing that, what are the current best practices for sharing > widgets? > > > > -Nathan > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: From hughesadam87 at gmail.com Fri Sep 19 14:01:25 2014 From: hughesadam87 at gmail.com (Adam Hughes) Date: Fri, 19 Sep 2014 14:01:25 -0400 Subject: [IPython-dev] Current status of sharing/publishing widgets? In-Reply-To: References: Message-ID: This question is also very interesting to our group! Just to clarify, are we talking about a use-case where nbconvert has a fully functioning GUI, or just that the GUI itself is visible in a static state? I think the latter is still kind of useful for teaching purposes. Thomas, considering that massive to-do list that must be on the IPython team's plate at this point, is there an estimated timetable for some of those plans you mentioned? On Fri, Sep 19, 2014 at 1:54 PM, Thomas Kluyver wrote: > It's worth mentioning that we have plans to make this use case easier. > There are three things we're planning to do: > > - Store widgets in the notebook document format, so they persist in a > notebook without having to rerun the cells generating them. > - Make a 'comms only kernel' that handles widget requests but not regular > execution messages, so you can expose it on the public internet > (relatively) safely. > - Make a tool that can iterate through all possible widget states and > record the output to a set of small files, so you can run simple > widget-driven things from a static file server. > > Thomas > > On 19 September 2014 01:18, Matthias Bussonnier < > bussonniermatthias at gmail.com> wrote: > >> Hi, >> No it cannot be shared currently on nbviewer. What I would suggest is >> building a single-cell app that feed the widget with precomputed data >> depending on the possibilities. It could be hosted on a Heroku-like >> platform but still require some extra work. >> >> Otherwise you have to ask people to download your lib and run it. >> -- >> M >> >> >> Envoy? de mon iPhone >> >> > Le 19 sept. 2014 ? 02:14, Nathan Goldbaum a >> ?crit : >> > >> > Hi all, >> > >> > I've recently been spending some time creating a widget that I'd >> ideally like to publish along with a paper submission to the arxiv. This >> would hopefully just be a link that readers could click on that would take >> them to a page where they can explore the widget without having to run the >> code or have all the data necessary to generate the widget from script. >> > >> > I know that there were plans to get something like this working for >> IPython 3.0. >> > >> > What is the current status? Is it possible to share widgets on e.g. >> nbviewer? Failing that, what are the current best practices for sharing >> widgets? >> > >> > -Nathan >> > _______________________________________________ >> > IPython-dev mailing list >> > IPython-dev at scipy.org >> > http://mail.scipy.org/mailman/listinfo/ipython-dev >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From takowl at gmail.com Fri Sep 19 14:05:24 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Fri, 19 Sep 2014 11:05:24 -0700 Subject: [IPython-dev] Current status of sharing/publishing widgets? In-Reply-To: References: Message-ID: On 19 September 2014 11:01, Adam Hughes wrote: > Thomas, considering that massive to-do list that must be on the IPython > team's plate at this point, is there an estimated timetable for some of > those plans you mentioned? Storing widgets in notebook files should be done within a couple of months. Jon, are we still aiming for 3.0 for that? The comms only kernel is also fairly easy, though it's not on anyone's to do list at the moment. Generating and freezing widget state, and general tooling for publishing widget-based interactive documents, are still some way off. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: From nick.bollweg at gmail.com Fri Sep 19 14:51:02 2014 From: nick.bollweg at gmail.com (Nicholas Bollweg) Date: Fri, 19 Sep 2014 14:51:02 -0400 Subject: [IPython-dev] Current status of sharing/publishing widgets? In-Reply-To: References: Message-ID: Perhaps having a mixin that added a demo or standalone method? Part of the challenge would be to inject all of the assets in a way that is embeddable (rather than linked)... as I imagine most of the time I'd really rather NOT embed all of my dependencies in every notebook. Whatever the resolution, I'd love to capture the result in cookiecutter-ipython-widget . Standalone demo notebooks would be a lovely addition. It originally started as something that would be easily pip installable, but now handles - asset juggling problem - sample notebook - travis testing -------------- next part -------------- An HTML attachment was scrubbed... URL: From hughesadam87 at gmail.com Fri Sep 19 15:02:44 2014 From: hughesadam87 at gmail.com (Adam Hughes) Date: Fri, 19 Sep 2014 15:02:44 -0400 Subject: [IPython-dev] Current status of sharing/publishing widgets? In-Reply-To: References: Message-ID: Nick, The official Ipython Notebook that you link on the github frontpage produces a 404 for me. Is it working for you? On Fri, Sep 19, 2014 at 2:51 PM, Nicholas Bollweg wrote: > Perhaps having a mixin that added a demo or standalone method? > > Part of the challenge would be to inject all of the assets in a way that > is embeddable (rather than linked)... as I imagine most of the time I'd > really rather NOT embed all of my dependencies in every notebook. > > Whatever the resolution, I'd love to capture the result in > cookiecutter-ipython-widget > . > > Standalone demo notebooks would be a lovely addition. > > It originally started as something that would be easily pip installable, > but now handles > - asset juggling problem > - sample notebook > - travis testing > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From takowl at gmail.com Fri Sep 19 15:06:05 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Fri, 19 Sep 2014 12:06:05 -0700 Subject: [IPython-dev] Current status of sharing/publishing widgets? In-Reply-To: References: Message-ID: On 19 September 2014 12:02, Adam Hughes wrote: > The official Ipython Notebook that you link on the github frontpage > produces a 404 for me. Is it working for you? > Sorry, that's one of our example notebooks. We break links to those more often than we should. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: From fperez.net at gmail.com Fri Sep 19 15:13:30 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Fri, 19 Sep 2014 12:13:30 -0700 Subject: [IPython-dev] Renumber cells for nbconvert In-Reply-To: References: <541B4A32.20204@fnal.gov> <541B504C.5050000@fnal.gov> <541B5235.9020701@fnal.gov> Message-ID: On Thu, Sep 18, 2014 at 3:12 PM, Doug Blank wrote: > Fair enough :) But, I did some more experimenting on master and found that > floating-point numbers seem to pass as valid (eg, it at least saves and > loads). That's because Javascript doesn't really have a proper integer type, as per the language spec. Stupid, idiotic, crazy, absurd to have a language built like that, but that's JS for you. -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: From nick.bollweg at gmail.com Fri Sep 19 15:14:33 2014 From: nick.bollweg at gmail.com (Nicholas Bollweg) Date: Fri, 19 Sep 2014 15:14:33 -0400 Subject: [IPython-dev] Current status of sharing/publishing widgets? In-Reply-To: References: Message-ID: @adam: thanks for pointing that out! master now points back at the 2.x branch (of ipython/ipython) casper (which is the start of travis stuff) and v3.0 now point at the new location and improved location in master... it's a feature! On Fri, Sep 19, 2014 at 3:06 PM, Thomas Kluyver wrote: > On 19 September 2014 12:02, Adam Hughes wrote: > >> The official Ipython Notebook that you link on the github frontpage >> produces a 404 for me. Is it working for you? >> > > Sorry, that's one of our example notebooks. We break links to those more > often than we should. > > Thomas > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From cyrille.rossant at gmail.com Fri Sep 19 15:18:10 2014 From: cyrille.rossant at gmail.com (Cyrille Rossant) Date: Fri, 19 Sep 2014 21:18:10 +0200 Subject: [IPython-dev] Renumber cells for nbconvert In-Reply-To: <541B4A32.20204@fnal.gov> References: <541B4A32.20204@fnal.gov> Message-ID: FYI here is a simple JS extension that linearly renumber all cells in the notebook: http://nbviewer.ipython.org/github/ipython-books/cookbook-code/blob/master/notebooks/chapter03_notebook/03_controls.ipynb 2014-09-18 23:10 GMT+02:00 Jon Wilson : > Hi, > We often share around nbconverted notebooks in my research group. But, > it is difficult to refer (when in a phone meeting) to specific figures > or pieces of code or other output in the notebook. This is because the > cells are often executed out of order, so they have non-sequential numbers. > > Now, in some situations, knowing the order of execution is crucial. > But usually in this case, the order is unimportant. The non-sequential > ordering is due to things like "oh, I made a mistake in the fifth > figure, let me try a few things to fix it, now the 4th figure needs to > be fixed too," etc. > > So, if it were possible to re-number the cells, either in the notebook > proper or in the nbconvert step, that would make our lives a little bit > easier. > > Alternatively, it would be pretty awesome if figures could have > automatic (sequential) figure numbering. Then the cell numbering > wouldn't matter nearly as much. > Regards, > Jon > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From takowl at gmail.com Fri Sep 19 18:12:52 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Fri, 19 Sep 2014 15:12:52 -0700 Subject: [IPython-dev] Notebook: Retaining mouse events when destroying elements with JS In-Reply-To: References: Message-ID: When you display output, clicking in there disables all of IPython's shortcuts, so that you can type normally if your output includes a text widget or something. Normally, when the focus leaves the output element, the shortcuts are enabled again. I guess that because you're deleting the element, the 'focus left' event isn't firing properly. This section of our code should illustrate how to work around it: https://github.com/ipython/ipython/blob/50ab9a900d617e41ecca11093e4bed2c2bb5ac03/IPython/html/static/notebook/js/keyboardmanager.js#L550 Thomas On 19 September 2014 08:55, Phil Elson wrote: > I've got a case where I'm implementing a button which removes some output > via JS when clicked. > The removal is working as expected, but IPython's keyboard events are no > longer firing after the button has been clicked. > > Essentially I have a single cell with the following: > > from IPython.display import HTML > > HTML(""" > > > > """) > > This is part of a more complex system which cannot currently make use of > the widget infrastructure, so wonder if anybody can give me any clues as to > how to prevent the IPython keyboard short-cuts from disappearing once the > button is pressed? > > Thanks! > > Phil > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From nick.bollweg at gmail.com Mon Sep 22 00:12:53 2014 From: nick.bollweg at gmail.com (Nicholas Bollweg) Date: Mon, 22 Sep 2014 00:12:53 -0400 Subject: [IPython-dev] more bootstrap widgets Message-ID: Here's a couple of widgets I've been putting together, extracted from other projects: https://github.com/bollwyvl/ip-bootstrap It's not a full release yet, but I figured some others might have some interest/opinions on the work up until now. Background: I have recently, both here on the list and for work, been buiding things that are more application-like in notebooks. I end up hacking up "chrome junk": control groups, layout grids, icons on buttons. Yes, these are very boring from a data point of view, probably overkill as widgets, etc... but are useful nonetheless, as the result Looks Good. Since Bootstrap and FontAwesome are already available, it seemed like a no-brainer to use them as the basis for this. Future: Not sure if any of this would be an acceptable PR to core, as it is pretty heavily tied to BS/FA, but perhaps certain features could be. The icon minilanguage is particularly funny: to show a huge, "good" space shuttle: Icon(fa.space_shuttle.context_success.rotate_180 * 5) Feedback welcome! -------------- next part -------------- An HTML attachment was scrubbed... URL: From robert.pollak at mykolab.com Mon Sep 22 00:50:25 2014 From: robert.pollak at mykolab.com (Robert Pollak) Date: Mon, 22 Sep 2014 06:50:25 +0200 Subject: [IPython-dev] exit() in a Spyder script Message-ID: <541FAA91.8030106@mykolab.com> [2nd try - it seems this didn't get posted because I was not subscribed.] Hello, I am using the Spyder IDE [1] within WinPython [2]. Spyder runs scripts within IPython. When I take a script containing exit(), and run it within Spyder, this command kills the Python kernel: """ It seems the kernel died unexpectedly. Use 'Restart kernel' to continue using this console. """ I have reported this to Spyder as issue 1974 [3], but I was told that > [...] the exception should be caught inside IPython itself. Is this true? In the IPython documentation I have read about an ask_exit() callback. Should Spyder register this callback to catch the exit()? Best regards, Robert [1] https://code.google.com/p/spyderlib/ [2] http://winpython.sourceforge.net/ [3] https://code.google.com/p/spyderlib/issues/detail?id=1974 From ccordoba12 at gmail.com Mon Sep 22 01:08:55 2014 From: ccordoba12 at gmail.com (=?UTF-8?B?Q2FybG9zIEPDs3Jkb2Jh?=) Date: Mon, 22 Sep 2014 00:08:55 -0500 Subject: [IPython-dev] exit() in a Spyder script In-Reply-To: <541FAA91.8030106@mykolab.com> References: <541FAA91.8030106@mykolab.com> Message-ID: <541FAEE7.6020201@gmail.com> Hi, We (the Spyder team) didn't want to wash our hands and transfer the problem to the IPython one :-) The thing is if you're calling exit(), you want the Python interpreter to terminate, and Spyder can't control this. However, I found an easy solution, following your suggestion about ask_exit: 1. Define a pass function like this: def f(): pass 2. Run this code in the IPython console: In [1]: ip = get_ipython() In [2]: ip.ask_exit = f Then exit() won't have any effect. If you want this code to always evaluate for any IPython Console in Spyder, you need to go to: Preferences > IPython Console > Startup > Run code and paste this line in the "Lines" text field: def f(): pass, get_ipython().ask_exit = f Cheers, Carlos El 21/09/14 a las #4, Robert Pollak escribi?: > [2nd try - it seems this didn't get posted because I was not subscribed.] > > Hello, > > I am using the Spyder IDE [1] within WinPython [2]. Spyder runs scripts > within IPython. When I take a script containing exit(), and run it > within Spyder, this command kills the Python kernel: > > """ > It seems the kernel died unexpectedly. Use 'Restart kernel' to continue > using this console. > """ > > I have reported this to Spyder as issue 1974 [3], but I was told that >> [...] the exception should be caught inside IPython itself. > Is this true? > In the IPython documentation I have read about an ask_exit() callback. > Should Spyder register this callback to catch the exit()? > > Best regards, > Robert > > > [1] https://code.google.com/p/spyderlib/ > [2] http://winpython.sourceforge.net/ > [3] https://code.google.com/p/spyderlib/issues/detail?id=1974 > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: From fperez.net at gmail.com Mon Sep 22 02:06:55 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Sun, 21 Sep 2014 23:06:55 -0700 Subject: [IPython-dev] Notebook link checker (URLs and images) Message-ID: Hi folks, we'll eventually want to move this into ipython/nbconvert, esp. so we can use it to validate our notebooks-as-docs for broken links and images... But I needed it *today* to package a talk, and with help from Brian we put together a quick and dirty link checker: https://gist.github.com/fperez/c591cab03c66780b18d5 It's very, very rough, but it does what I need for now, and we can use it as a starting point for a more robust tool in IPython proper. Since others may have similar needs, feel free to just grab the script (100% self-contained, only external deps are requests and Beautiful Soup) and modify it to your needs. Cheers f -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: From bussonniermatthias at gmail.com Mon Sep 22 03:31:08 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Mon, 22 Sep 2014 09:31:08 +0200 Subject: [IPython-dev] more bootstrap widgets In-Reply-To: References: Message-ID: <4934CBAA-D336-44AB-81BA-F73E41EBFB69@gmail.com> Le 22 sept. 2014 ? 06:12, Nicholas Bollweg a ?crit : > Here's a couple of widgets I've been putting together, extracted from other projects: > > https://github.com/bollwyvl/ip-bootstrap thanks awesome. > > It's not a full release yet, but I figured some others might have some interest/opinions on the work up until now. > > Background: I have recently, both here on the list and for work, been buiding things that are more application-like in notebooks. I end up hacking up "chrome junk": control groups, layout grids, icons on buttons. Yes, these are very boring from a data point of view, probably overkill as widgets, etc... but are useful nonetheless, as the result Looks Good. Since Bootstrap and FontAwesome are already available, it seemed like a no-brainer to use them as the basis for this. > > Future: Not sure if any of this would be an acceptable PR to core, as it is pretty heavily tied to BS/FA, but perhaps certain features could be. Probably not **now** we want to split widget in a separate repo to allow faster development. So we keep minimal things in the core. > > The icon minilanguage is particularly funny: to show a huge, "good" space shuttle: > > Icon(fa.space_shuttle.context_success.rotate_180 * 5) You should add some screnshot to the read me :-) Haven't looked at the source deeply, but have you thought of how this would integrate into non-python package ? Like a way to reuse the js part with julia/ruby? etc ? Thanks , you can add a link to that on the wiki, and don't forget the Framework:IPython on PyPi :-) -- M > > Feedback welcome! > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: From pelson.pub at gmail.com Mon Sep 22 05:43:05 2014 From: pelson.pub at gmail.com (Phil Elson) Date: Mon, 22 Sep 2014 10:43:05 +0100 Subject: [IPython-dev] Notebook: Retaining mouse events when destroying elements with JS In-Reply-To: References: Message-ID: Thanks for the pointer Thomas, Simply adding *IPython.keyboard_manager.enable()* to the event fixed the problem. On 19 September 2014 23:12, Thomas Kluyver wrote: > When you display output, clicking in there disables all of IPython's > shortcuts, so that you can type normally if your output includes a text > widget or something. Normally, when the focus leaves the output element, > the shortcuts are enabled again. I guess that because you're deleting the > element, the 'focus left' event isn't firing properly. > > This section of our code should illustrate how to work around it: > > https://github.com/ipython/ipython/blob/50ab9a900d617e41ecca11093e4bed2c2bb5ac03/IPython/html/static/notebook/js/keyboardmanager.js#L550 > > Thomas > > > On 19 September 2014 08:55, Phil Elson wrote: > >> I've got a case where I'm implementing a button which removes some output >> via JS when clicked. >> The removal is working as expected, but IPython's keyboard events are no >> longer firing after the button has been clicked. >> >> Essentially I have a single cell with the following: >> >> from IPython.display import HTML >> >> HTML(""" >> >> >> >> """) >> >> This is part of a more complex system which cannot currently make use of >> the widget infrastructure, so wonder if anybody can give me any clues as to >> how to prevent the IPython keyboard short-cuts from disappearing once the >> button is pressed? >> >> Thanks! >> >> Phil >> >> >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From nick.bollweg at gmail.com Mon Sep 22 09:23:32 2014 From: nick.bollweg at gmail.com (Nicholas Bollweg) Date: Mon, 22 Sep 2014 09:23:32 -0400 Subject: [IPython-dev] more bootstrap widgets In-Reply-To: <4934CBAA-D336-44AB-81BA-F73E41EBFB69@gmail.com> References: <4934CBAA-D336-44AB-81BA-F73E41EBFB69@gmail.com> Message-ID: Thanks for the feedback! About reuse: i haven't tried out other kernels yet, but portability to other backends seems easier than other frontends (say, polymer and icomoon)... Is implementing the widget spec part of the price of admission for being a kernel? I guess i haven't seen a Rosetta example of a widget for all known backends. The widgets themselves are very simple, usually just declaring traits and maybe providing a vanity init... *args as children, or value. Other than the enums of bootstrap stuff, which could follow font-awesome into json files, a lot of non widget code is there for dealing with loading assets... Presumably this will get better when the require redactor lands. What will widget distribution look like in a multi kernel world? it seems like an implementation of a front end would go on bower (or equivalent), and then one could see which other back ends had implementations for it, from their respective package managers. I suppose this could go both ways, with a single, declarative, versioned spec of traits and events (ex. Bower:jptr-barchart-spec... As json or better still, .jsonld) in the middle. Then multiple frontends (bower:jptr-barchart-nvd3 and bower:jptr-barchart-highcharts) as well as multiple backends (pypi:ip-barchart and cran:ir-barchart), even for a single kernel (pypi:ip-barchart-numpy), could harmoniously coexist, and develop independently. Presumably, the user would not have to know any of this, just install and use the implementation of their choice. This again raises the question of an extension registry website/cli where one could see all of this in one place, as this sounds hard to manage from a configuration management point of view... Is this already on the roadmap somewhere? On Sep 22, 2014 3:28 AM, "Matthias Bussonnier" wrote: > > Le 22 sept. 2014 ? 06:12, Nicholas Bollweg a ?crit : > > Here's a couple of widgets I've been putting together, extracted from > other projects: > > https://github.com/bollwyvl/ip-bootstrap > > > > thanks awesome. > > > It's not a full release yet, but I figured some others might have some > interest/opinions on the work up until now. > > Background: I have recently, both here on the list and for work, been > buiding things that are more application-like in notebooks. I end up > hacking up "chrome junk": control groups, layout grids, icons on buttons. > Yes, these are very boring from a data point of view, probably overkill as > widgets, etc... but are useful nonetheless, as the result Looks Good. Since > Bootstrap and FontAwesome are already available, it seemed like a > no-brainer to use them as the basis for this. > > Future: Not sure if any of this would be an acceptable PR to core, as it > is pretty heavily tied to BS/FA, but perhaps certain features could be. > > > Probably not **now** we want to split widget in a separate repo to allow > faster development. So we keep minimal things in the core. > > > The icon minilanguage is particularly funny: to show a huge, "good" space > shuttle: > > Icon(fa.space_shuttle.context_success.rotate_180 * 5) > > > You should add some screnshot to the read me :-) > > Haven't looked at the source deeply, but have you thought of how this > would integrate into non-python package ? > Like a way to reuse the js part with julia/ruby? etc ? > > Thanks , you can add a link to that on the wiki, and don't forget the > Framework:IPython on PyPi :-) > > -- > M > > > > > Feedback welcome! > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bussonniermatthias at gmail.com Mon Sep 22 10:52:34 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Mon, 22 Sep 2014 16:52:34 +0200 Subject: [IPython-dev] more bootstrap widgets In-Reply-To: References: <4934CBAA-D336-44AB-81BA-F73E41EBFB69@gmail.com> Message-ID: Le 22 sept. 2014 ? 15:23, Nicholas Bollweg a ?crit : > Thanks for the feedback! > > About reuse: i haven't tried out other kernels yet, but portability to other backends seems easier than other frontends (say, polymer and icomoon)? > > Is implementing the widget spec part of the price of admission for being a kernel? > No it is not, a kernel is whatever does not make things crash :-) I suppose as soon as you get execute/reply you are a kernel. If something is not available, we do our best to just not expose functionality. > I guess i haven't seen a Rosetta example of a widget for all known backends. > > The widgets themselves are very simple, usually just declaring traits and maybe providing a vanity init... *args as children, or value. Other than the enums of bootstrap stuff, which could follow font-awesome into json files, a lot of non widget code is there for dealing with loading assets... Presumably this will get better when the require redactor lands. > > What will widget distribution look like in a multi kernel world? it seems like an implementation of a front end would go on bower (or equivalent), and then one could see which other back ends had implementations for it, from their respective package managers. > > I suppose this could go both ways, with a single, declarative, versioned spec of traits and events (ex. Bower:jptr-barchart-spec... As json or better still, .jsonld) in the middle. > > Then multiple frontends (bower:jptr-barchart-nvd3 and bower:jptr-barchart-highcharts) as well as multiple backends (pypi:ip-barchart and cran:ir-barchart), even for a single kernel (pypi:ip-barchart-numpy), could harmoniously coexist, and develop independently. Presumably, the user would not have to know any of this, just install and use the implementation of their choice. > Yes, these 3 were basically the center of my question. The only problem I see here, is that it is hard to force users to user YAPM (yet another package manager) to install dependencies. And problem with bower is that it requires node and npm IIRC. Also how do you tell bower the 'right location' to put theses components, and what if theses require different version of same component.. > This again raises the question of an extension registry website/cli where one could see all of this in one place, as this sounds hard to manage from a configuration management point of view... Is this already on the roadmap somewhere? > No, unfortunately, and this might be a little bit out of scope for IPython/Jupyter right now. But definitively something we will have to handle at some point. -- M > On Sep 22, 2014 3:28 AM, "Matthias Bussonnier" wrote: > > Le 22 sept. 2014 ? 06:12, Nicholas Bollweg a ?crit : > >> Here's a couple of widgets I've been putting together, extracted from other projects: >> >> https://github.com/bollwyvl/ip-bootstrap > > > thanks awesome. > >> >> It's not a full release yet, but I figured some others might have some interest/opinions on the work up until now. >> >> Background: I have recently, both here on the list and for work, been buiding things that are more application-like in notebooks. I end up hacking up "chrome junk": control groups, layout grids, icons on buttons. Yes, these are very boring from a data point of view, probably overkill as widgets, etc... but are useful nonetheless, as the result Looks Good. Since Bootstrap and FontAwesome are already available, it seemed like a no-brainer to use them as the basis for this. >> >> Future: Not sure if any of this would be an acceptable PR to core, as it is pretty heavily tied to BS/FA, but perhaps certain features could be. > > Probably not **now** we want to split widget in a separate repo to allow faster development. So we keep minimal things in the core. > >> >> The icon minilanguage is particularly funny: to show a huge, "good" space shuttle: >> >> Icon(fa.space_shuttle.context_success.rotate_180 * 5) > > You should add some screnshot to the read me :-) > > Haven't looked at the source deeply, but have you thought of how this would integrate into non-python package ? > Like a way to reuse the js part with julia/ruby? etc ? > > Thanks , you can add a link to that on the wiki, and don't forget the Framework:IPython on PyPi :-) > > -- > M > > > >> >> Feedback welcome! >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: From nick.bollweg at gmail.com Mon Sep 22 11:50:40 2014 From: nick.bollweg at gmail.com (Nicholas Bollweg) Date: Mon, 22 Sep 2014 11:50:40 -0400 Subject: [IPython-dev] more bootstrap widgets In-Reply-To: References: <4934CBAA-D336-44AB-81BA-F73E41EBFB69@gmail.com> Message-ID: Re: YAPM: yeah, definitely see that as creep for end user... however, as a developer, the whole copy-files-to-nbextensions thing is a little annoying. Would requiring a module maintainer to have bower be out-of-line? See lessc, bower, etc. for current statics. Then maintainers can adopt the bower management/packaging approach, and have the serving of this managed by bowerstatic[1] or a suitably tornadoified version. Instead of needing bower at install/runtime, it appears to be fairly common practice to check in bower_components for statically-hosted brower-based applications. For a maintainer, this could be managed during development just like it is currently in core: submoduled in, but then copied in on build. Each of these sets of components is then managed in bowerstatic as an "isolated universe"[2]. In addition to _view_module, an implementer would also offer _view_components, specifying a single, static location. So long as everything is managed with requirejs, everything should just work :) [1]: http://bowerstatic.readthedocs.org [2]: http://bowerstatic.readthedocs.org/en/latest/integrating.html#declaring-bower-directories -------------- next part -------------- An HTML attachment was scrubbed... URL: From lucienboillod at gmail.com Tue Sep 23 03:27:27 2014 From: lucienboillod at gmail.com (Lucien Boillod) Date: Tue, 23 Sep 2014 09:27:27 +0200 Subject: [IPython-dev] Absolute Path IPython Message-ID: <519350F2-4448-4DA5-85E3-B39207422A1C@gmail.com> Hello, Why can we not do a absolute path to find or read some files ? This is really a inconvenience because I would like the user can access, anywhere he is, to the documentation installed in a folder into my project, but without he has to find the way. But I can?t implement a magic_command line like ?doc?, that open the file ?index.ipynb? which is installed inside the project in a predefined path, because it?s not all allow absolute PATH. So if you have a simple way to do my trick ? Kindest regards From bussonniermatthias at gmail.com Tue Sep 23 03:43:49 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Tue, 23 Sep 2014 09:43:49 +0200 Subject: [IPython-dev] Absolute Path IPython In-Reply-To: <519350F2-4448-4DA5-85E3-B39207422A1C@gmail.com> References: <519350F2-4448-4DA5-85E3-B39207422A1C@gmail.com> Message-ID: Hi Lucien, Can you give more context to what you are trying to achieve ? Like an example or a link to your project? Usually you should be able to use absolute path in IPython to read files. Cheers, -- M Envoy? de mon iPhone > Le 23 sept. 2014 ? 09:27, Lucien Boillod a ?crit : > > Hello, > > Why can we not do a absolute path to find or read some files ? This is really a inconvenience because I would like the user can access, anywhere he is, to the documentation installed in a folder into my project, but without he has to find the way. But I can?t implement a magic_command line like ?doc?, that open the file ?index.ipynb? which is installed inside the project in a predefined path, because it?s not all allow absolute PATH. > So if you have a simple way to do my trick ? > > Kindest regards > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From kikocorreoso at gmail.com Tue Sep 23 03:49:52 2014 From: kikocorreoso at gmail.com (Kiko) Date: Tue, 23 Sep 2014 09:49:52 +0200 Subject: [IPython-dev] Renumber cells for nbconvert In-Reply-To: References: <541B4A32.20204@fnal.gov> Message-ID: For the cell renumbering I did this: http://nbviewer.ipython.org/github/kikocorreoso/brythonmagic/blob/master/notebooks/Brython%20usage%20in%20the%20IPython%20notebook.ipynb#Include-the-cell-number-for-each-cell I add additional info in the prompt area. It is made using Brython (see https://github.com/kikocorreoso/brythonmagic for more info) but you could easily translate that to JS. Warning: I don't know if I am breaking something of the nb structure or if what I'm using to get the cell numbers will be available on later versions. 2014-09-19 21:18 GMT+02:00 Cyrille Rossant : > FYI here is a simple JS extension that linearly renumber all cells in > the notebook: > > > http://nbviewer.ipython.org/github/ipython-books/cookbook-code/blob/master/notebooks/chapter03_notebook/03_controls.ipynb > > 2014-09-18 23:10 GMT+02:00 Jon Wilson : > > Hi, > > We often share around nbconverted notebooks in my research group. But, > > it is difficult to refer (when in a phone meeting) to specific figures > > or pieces of code or other output in the notebook. This is because the > > cells are often executed out of order, so they have non-sequential > numbers. > > > > Now, in some situations, knowing the order of execution is crucial. > > But usually in this case, the order is unimportant. The non-sequential > > ordering is due to things like "oh, I made a mistake in the fifth > > figure, let me try a few things to fix it, now the 4th figure needs to > > be fixed too," etc. > > > > So, if it were possible to re-number the cells, either in the notebook > > proper or in the nbconvert step, that would make our lives a little bit > > easier. > > > > Alternatively, it would be pretty awesome if figures could have > > automatic (sequential) figure numbering. Then the cell numbering > > wouldn't matter nearly as much. > > Regards, > > Jon > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: From lucienboillod at gmail.com Tue Sep 23 04:46:35 2014 From: lucienboillod at gmail.com (Lucien Boillod) Date: Tue, 23 Sep 2014 10:46:35 +0200 Subject: [IPython-dev] Absolute Path IPython In-Reply-To: References: <519350F2-4448-4DA5-85E3-B39207422A1C@gmail.com> Message-ID: Hi, Sorry if I didn?t explain as well my problem. I have my documentation inside a folder, into a predefined path that I can call with a command (vcsn.datadir), in function where you are (when you open your Ipython notebook) the function return the correct path to access to the doc. I would like to open some files in this folder ( this is .ipynb files) so I tried this : import webbrowser def doc(m): url = 'localhost:8888' + vcsn.datadir + '/notebooks/algos/' + m + '.ipynb' webbrowser.open(url) doc(?automaton.proper?) But this isn?t work. Firstly because we are not obviously in the localhost 8888, it can be 8834 or whatever, but I don?t know how to catch the local host of our notebook session. Secondly because it seems not recognize this path, but if I go handly to this path there is the file, and I can open automaton.proper.ipynb. Le 23 sept. 2014 ? 09:43, Matthias Bussonnier a ?crit : > Hi Lucien, > > Can you give more context to what you are trying to achieve ? Like an example or a link to your project? > Usually you should be able to use absolute path in IPython to read files. > > Cheers, > -- > M > > Envoy? de mon iPhone > >> Le 23 sept. 2014 ? 09:27, Lucien Boillod a ?crit : >> >> Hello, >> >> Why can we not do a absolute path to find or read some files ? This is really a inconvenience because I would like the user can access, anywhere he is, to the documentation installed in a folder into my project, but without he has to find the way. But I can?t implement a magic_command line like ?doc?, that open the file ?index.ipynb? which is installed inside the project in a predefined path, because it?s not all allow absolute PATH. >> So if you have a simple way to do my trick ? >> >> Kindest regards >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From lucienboillod at gmail.com Tue Sep 23 04:52:34 2014 From: lucienboillod at gmail.com (Lucien Boillod) Date: Tue, 23 Sep 2014 10:52:34 +0200 Subject: [IPython-dev] Absolute Path IPython In-Reply-To: References: <519350F2-4448-4DA5-85E3-B39207422A1C@gmail.com> Message-ID: What I simply tried to say is we can?t go down repository when we open a notebook. Example we are in Documents/ and we open a new notebook. Now we can?t open a file which is before Documents/ we only can hike the path from Documents/../.. and can?t ../../Documents. Le 23 sept. 2014 ? 09:43, Matthias Bussonnier a ?crit : > Hi Lucien, > > Can you give more context to what you are trying to achieve ? Like an example or a link to your project? > Usually you should be able to use absolute path in IPython to read files. > > Cheers, > -- > M > > Envoy? de mon iPhone > >> Le 23 sept. 2014 ? 09:27, Lucien Boillod a ?crit : >> >> Hello, >> >> Why can we not do a absolute path to find or read some files ? This is really a inconvenience because I would like the user can access, anywhere he is, to the documentation installed in a folder into my project, but without he has to find the way. But I can?t implement a magic_command line like ?doc?, that open the file ?index.ipynb? which is installed inside the project in a predefined path, because it?s not all allow absolute PATH. >> So if you have a simple way to do my trick ? >> >> Kindest regards >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From bussonniermatthias at gmail.com Tue Sep 23 05:41:51 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Tue, 23 Sep 2014 11:41:51 +0200 Subject: [IPython-dev] Absolute Path IPython In-Reply-To: References: <519350F2-4448-4DA5-85E3-B39207422A1C@gmail.com> Message-ID: <8CD68300-E810-4E96-92BA-EDD611BB9C32@gmail.com> Hi lucien, Thanks for the explanation, I better understand what you want to do. You are trying do build something under some assumption that are wrong and cannot reliably always work. Let assume the following: - I am on my laptop (it does not have python installed) - the IPython notebook server is on my Desktop with an open port on the internet. - My kernel were my code runs in on my lab cluster. Webbrower.open(url) is runned on the cluster, though the ipynb files are obviously on my desktop, and what you want is open a page on your laptop. So this cannot reliably work. It needs you to get information on the network architecture you might not have. That beeing said. You might be able to workaround by : - display html instead of trying web browser open - avoid absolute url, use '/notebook/' - have a look at nbopen[1] that does what you ask in **some** cases You cannot get around the fact that you cannot access ../ url thing. It is a question of **security**. You project of having ipynb as documentation is interesting, we would be glad to see how you did it, and how it feels for users. We have a long term project in doing something alike, but not yet completely defined. Thanks, -- M [1]: https://github.com/takluyver/nbopen Le 23 sept. 2014 ? 10:46, Lucien Boillod a ?crit : > Hi, > > Sorry if I didn?t explain as well my problem. I have my documentation inside a folder, into a predefined path that I can call with a command (vcsn.datadir), in function where you are (when you open your Ipython notebook) the function return the correct path to access to the doc. > I would like to open some files in this folder ( this is .ipynb files) so I tried this : > import webbrowser > def doc(m): > url = 'localhost:8888' + vcsn.datadir + '/notebooks/algos/' + m + '.ipynb' > webbrowser.open(url) > > doc(?automaton.proper?) > > But this isn?t work. Firstly because we are not obviously in the localhost 8888, it can be 8834 or whatever, but I don?t know how to catch the local host of our notebook session. Secondly because it seems not recognize this path, but if I go handly to this path there is the file, and I can open automaton.proper.ipynb. > What I simply tried to say is we can?t go down repository when we open a notebook. > Example we are in Documents/ and we open a new notebook. Now we can?t open a file which is before > Documents/ we only can hike the path from Documents/../.. and can?t ../../Documents. > > > Le 23 sept. 2014 ? 09:43, Matthias Bussonnier a ?crit : > >> Hi Lucien, >> >> Can you give more context to what you are trying to achieve ? Like an example or a link to your project? >> Usually you should be able to use absolute path in IPython to read files. >> >> Cheers, >> -- >> M >> >> Envoy? de mon iPhone >> >>> Le 23 sept. 2014 ? 09:27, Lucien Boillod a ?crit : >>> >>> Hello, >>> >>> Why can we not do a absolute path to find or read some files ? This is really a inconvenience because I would like the user can access, anywhere he is, to the documentation installed in a folder into my project, but without he has to find the way. But I can?t implement a magic_command line like ?doc?, that open the file ?index.ipynb? which is installed inside the project in a predefined path, because it?s not all allow absolute PATH. >>> So if you have a simple way to do my trick ? >>> >>> Kindest regards >>> _______________________________________________ >>> IPython-dev mailing list >>> IPython-dev at scipy.org >>> http://mail.scipy.org/mailman/listinfo/ipython-dev >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: From akim at lrde.epita.fr Tue Sep 23 07:50:32 2014 From: akim at lrde.epita.fr (Akim Demaille) Date: Tue, 23 Sep 2014 13:50:32 +0200 Subject: [IPython-dev] Absolute Path IPython In-Reply-To: <8CD68300-E810-4E96-92BA-EDD611BB9C32@gmail.com> References: <519350F2-4448-4DA5-85E3-B39207422A1C@gmail.com> <8CD68300-E810-4E96-92BA-EDD611BB9C32@gmail.com> Message-ID: <8963E105-A69C-45B9-BB87-19D0902A0155@lrde.epita.fr> Le 23 sept. 2014 ? 11:41, Matthias Bussonnier a ?crit : > Hi lucien, Hi Matthias, Thanks for the answer. > Thanks for the explanation, I better understand what you want to do. > You are trying do build something under some assumption that are wrong and cannot reliably always work. Yes, we know :) That's why we are looking for The Better Way. > Let assume the following: > > - I am on my laptop (it does not have python installed) > - the IPython notebook server is on my Desktop with an open port on the internet. > - My kernel were my code runs in on my lab cluster. > > Webbrower.open(url) is runned on the cluster, though the ipynb files are obviously on my desktop, and what you want is open a page on your laptop. So this cannot reliably work. It needs you to get information on the network architecture you might not have. This is not right, the notebooks we are referring to here are where the server is. Our application, Vaucanson, is a Python binding of a C++ library. "make install" installs not only the shared libs and Python modules, but also a collection of notebooks (some of them can be looked at here: https://www.lrde.epita.fr/dload//vaucanson/2.0/notebooks/algos/ Here they are available both as notebooks, and html. Unfortunately on occasion the Mathjax rendering is broken, but I have read somewhere this is known, and fixed in the repo (for instance https://www.lrde.epita.fr/dload/vaucanson/2.0/notebooks/algos/automaton.reduce.html) I agree though that our use case is not taking the full generality of what IPython can do. > That beeing said. You might be able to workaround by : > > - display html instead of trying web browser open This is possible, indeed. Which means that we should also install the html rendering. Why not, after all. > - avoid absolute url, use '/notebook/' yes we need to address the scenario where the user fired the notebook from /home/foo, yet the documentation is in /usr/local. > - have a look at nbopen[1] that does what you ask in **some** cases > > You cannot get around the fact that you cannot access ../ url thing. It is a question of **security**. We understand that. However, since the user launches the notebook via a wrapper of ours, we would be happy if there were a means, from the command line or elsewhere, to pre-approve some other paths. > You project of having ipynb as documentation is interesting, we would be glad to see how you did it, and how it feels for users. Currently it feels bad, as it is not interactive: the user has to open the documentation page but hand, and then click. It's precisely to make her life easier that we are trying to have some thing like "?"/"??", but which would open these pages. Inline rendering of HTML would also be ok actually. Thanks again! From bussonniermatthias at gmail.com Tue Sep 23 08:25:36 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Tue, 23 Sep 2014 14:25:36 +0200 Subject: [IPython-dev] Absolute Path IPython In-Reply-To: <8963E105-A69C-45B9-BB87-19D0902A0155@lrde.epita.fr> References: <519350F2-4448-4DA5-85E3-B39207422A1C@gmail.com> <8CD68300-E810-4E96-92BA-EDD611BB9C32@gmail.com> <8963E105-A69C-45B9-BB87-19D0902A0155@lrde.epita.fr> Message-ID: <11EA3DEB-3971-4756-9ED7-824CC9F22EF9@gmail.com> Hi, Le 23 sept. 2014 ? 13:50, Akim Demaille a ?crit : >> Thanks for the explanation, I better understand what you want to do. >> You are trying do build something under some assumption that are wrong and cannot reliably always work. > > Yes, we know :) That's why we are looking for The Better Way. > >> Let assume the following: >> >> - I am on my laptop (it does not have python installed) >> - the IPython notebook server is on my Desktop with an open port on the internet. >> - My kernel were my code runs in on my lab cluster. >> >> Webbrower.open(url) is runned on the cluster, though the ipynb files are obviously on my desktop, and what you want is open a page on your laptop. So this cannot reliably work. It needs you to get information on the network architecture you might not have. > > This is not right, the notebooks we are referring to here > are where the server is. Our application, Vaucanson, is > a Python binding of a C++ library. "make install" installs > not only the shared libs and Python modules, but also a > collection of notebooks (some of them can be looked at here: > > https://www.lrde.epita.fr/dload//vaucanson/2.0/notebooks/algos/ > > Here they are available both as notebooks, and html. Unfortunately > on occasion the Mathjax rendering is broken, but I have read > somewhere this is known, and fixed in the repo (for instance > https://www.lrde.epita.fr/dload/vaucanson/2.0/notebooks/algos/automaton.reduce.html) Yep, you can just replace by and it should work. Your use case make more sens if you have your own application. > > I agree though that our use case is not taking the full > generality of what IPython can do. > >> That beeing said. You might be able to workaround by : >> >> - display html instead of trying web browser open > > This is possible, indeed. Which means that we should also install > the html rendering. Why not, after all. I was referring in using the IPython display machinery to show a ilk to the user, and this link could open another tab. Yo could even use js to trigger the opening of this tab. If you look at what Julia is doing, their "info methods" for "objects" do return html with direct link to github source code. As you know the hash of the current version of the project, you can directly link to a rendered version. Which also avoid to build the doc locally, but I won't go into the debatee of having or not local build of docs. > >> - avoid absolute url, use '/notebook/' > > yes we need to address the scenario where the user fired the > notebook from /home/foo, yet the documentation is in /usr/local. > >> - have a look at nbopen[1] that does what you ask in **some** cases >> >> You cannot get around the fact that you cannot access ../ url thing. It is a question of **security**. > > We understand that. However, since the user launches the > notebook via a wrapper of ours, we would be happy if there > were a means, from the command line or elsewhere, to pre-approve > some other paths. This is a complicated problem, and we are not sure wether or not sure we want to go to that route yet. One easy way would be for the time being to symlink into the home folder. Also you probably want these notebook to be immutable I suppose, which might force some refactor. > >> You project of having ipynb as documentation is interesting, we would be glad to see how you did it, and how it feels for users. > > Currently it feels bad, as it is not interactive: the user > has to open the documentation page but hand, and then click. > It's precisely to make her life easier that we are trying > to have some thing like "?"/"??", but which would open these > pages. Inline rendering of HTML would also be ok actually. That is also our long term goal, but we are low on bandwidth to deal with it. There are security questions, as with this docs could become attack vectors. And how do you render theses docs on non-html capable frontend. One thing I can see you doing, is if you can export to html fragments, is having doc('somehting') just return a IPython.display.HTML object with the content of the doc. This would allow to see doc in the notebook. (Note that ?/?? are actually %pinfo ind %pinfo2 magics, so you might be able to hook in there. ) If you want to go to the ?/?? route, you could define an @property def __doc__(self): ?. That fetch and return whatever is needed. We don't have a way (yet) to display rich things wit ?/?? but investigation on this would be welcomed. Julia is also going this way with a global registry of object/help and yo can query the help local db for a specific format. I'll think of a non-ivasive way to deploy an extension that can allow easier integration of your ipynb docs. -- M > Thanks again! > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From doug.blank at gmail.com Tue Sep 23 22:50:05 2014 From: doug.blank at gmail.com (Doug Blank) Date: Tue, 23 Sep 2014 22:50:05 -0400 Subject: [IPython-dev] Highlighting code as program runs? Message-ID: We are currently running an external kernel (Scheme) based on the "wrapper kernel" [1]. We would like to have a mode such that we could highlight the expression in the code cell as the program "runs". Is there an example of something like this? If not, what would be the recommended method to do this? Perhaps a CodeWidget, with specialized comm message handling to highlight the text, with stepper controls? I see that CodeMirror supports highlighting an area [2]. Now, just need to be able to send the region bounds as the program runs, and receive them. Any pointers appreciated, -Doug [1] - http://ipython.org/ipython-doc/dev/development/wrapperkernels.html [2] - cell.code_mirror.markText({line: 6, ch: 2}, {line: 6, ch: 5}, {className: "styled-background"}); -------------- next part -------------- An HTML attachment was scrubbed... URL: From one at kentran.net Tue Sep 23 23:39:56 2014 From: one at kentran.net (Kenneth Tran) Date: Tue, 23 Sep 2014 20:39:56 -0700 Subject: [IPython-dev] Pass variable to a ! command Message-ID: Hi, I'd like to pass Python variables as arguments to a system command. However, perhaps due to the command line syntax of my program (which accepts nested options via {}), this doesn't work. [image: Inline image 1] It looks like that when IPython fails to parse one of the variable names or expressions, it treats the whole command line as raw string. Here's a simpler example [image: Inline image 2] Should it try to parse variable names and/or expressions as much as it can? What files should I look into if I want to fix this? Thanks. -Ken -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image.png Type: image/png Size: 21702 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image.png Type: image/png Size: 56740 bytes Desc: not available URL: From one at kentran.net Wed Sep 24 02:06:50 2014 From: one at kentran.net (Kenneth Tran) Date: Tue, 23 Sep 2014 23:06:50 -0700 Subject: [IPython-dev] Real-time console output in notebooks Message-ID: Is it possible to see real-time output of a system command? It seems that while IPython shows real-time output, IPython notebook doesn't. Or am I doing anything wrong? Which leads to another point. I recently tried to compile with !bang in a notebook. It got hang indefinitely. Then I ssh to the machine and do the same thing (cd to a directory and call make) and this one finished rather quickly, albeit with some errors. Is there any explanation for why the command in the notebook didn't terminate? Thanks. -Ken -------------- next part -------------- An HTML attachment was scrubbed... URL: From bussonniermatthias at gmail.com Wed Sep 24 03:01:58 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Wed, 24 Sep 2014 09:01:58 +0200 Subject: [IPython-dev] Pass variable to a ! command In-Reply-To: References: Message-ID: <50B88400-822F-4837-BB79-7C83E21FF542@gmail.com> Le 24 sept. 2014 ? 05:39, Kenneth Tran a ?crit : > Hi, > > I'd like to pass Python variables as arguments to a system command. However, perhaps due to the command line syntax of my program (which accepts nested options via {}), this doesn't work. > > > > It looks like that when IPython fails to parse one of the variable names or expressions, it treats the whole command line as raw string. Here's a simpler example > > > > Should it try to parse variable names and/or expressions as much as it can? No it does bail out on first error. escape brackets : In [6]: bar = 1 In [7]: ! echo \{bar\} {bar} or use an intermediate string. In [8]: foo = '{bar}' In [9]: !echo {foo} {bar} to pass the dollars raw, use double dollar. $$ See explanation here: https://github.com/ipython/ipython/issues/6527 > What files should I look into if I want to fix this? I'm not sure it is something that can be "fixed" (i.e., the current behavior have probably have reasons). But it is the %sx magic IPython/core/magics/osm.py And might be a general behavior of line magic to expand $foo and {foo}. -- M > > Thanks. > -Ken > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: From one at kentran.net Wed Sep 24 04:48:28 2014 From: one at kentran.net (Kenneth Tran) Date: Wed, 24 Sep 2014 01:48:28 -0700 Subject: [IPython-dev] Issues with shell commands in IPython Notebook (Windows version) Message-ID: I have 2 instances of IPython NBServer running, one runs on Linux and the other runs on Windows. Let's call them NB-Win and NB-Linux. On both machines, IPython was installed using Anaconda. The experience of calling shell commands on NB-Win has been terrible. Many commands hang for no reason. I've tried *!wget http://www.csie.ntu.edu.tw/~cjlin/libsvmtools/datasets/binary/kddb.t.bz2 * (which is just 25MB) in a notebook on both servers. *On NB-Win* The command always failed to terminate. It hangs like this forever [image: Inline image 1] When I looked at the *wget* process in Process Explorer, none of the numbers (CPU, memory, IO, network, etc.) moved. If I killed the process, then now the cell returned something, like this [image: Inline image 3] The experience is the same with other commands. For example, I tried going to a directory and calling *!make*, and that one also didn't terminate. For comparison, this is what looks like when I run the same command using NB-Linux. The output is displayed as the program is running and the program exits in a few seconds. [image: Inline image 2] *So my questions are* 1. Why does the above command above (as well as many others) hang in NB-Win? (I could replicate this issue easily on my other Windows machines.) 2. Why can't NB-Win display console output in real-time as the program is running? While both NB-Linux and IPython shell on Windows/Linux can. 3. Why does NB-Win display a different output (or error?) string than what IPython-Win shell (on the same machine) produces? Both invoke the same *C:\Cygwin\bin\wget.exe* command line. [image: Inline image 5] Those issues have driven me crazy. I would appreciate any help. -Ken -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image.png Type: image/png Size: 13422 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image.png Type: image/png Size: 7021 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image.png Type: image/png Size: 27037 bytes Desc: not available URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: image.png Type: image/png Size: 36092 bytes Desc: not available URL: From dave.hirschfeld at gmail.com Wed Sep 24 05:06:09 2014 From: dave.hirschfeld at gmail.com (Dave Hirschfeld) Date: Wed, 24 Sep 2014 09:06:09 +0000 (UTC) Subject: [IPython-dev] git describe doesn't work? Message-ID: I've observed that git describe doesn't seem to work properly with the ipython repo which makes my conda dev builds have the wrong version number. Not sure there is anything that can be done, but in case there is, it would be nice to have git describe working. Thanks, Dave C:\dev\code\ipython [master...origin/master]> git describe --tags -- dirty rel-2.0.0-1644-ga2e1c67 C:\dev\code\ipython [master...origin/master]> git tag -l dev-0.11 rel-0.10 rel-0.10.1 rel-0.10.2 rel-0.11 rel-0.12 rel-0.12.1 rel-0.13 rel-0.13.1 rel-0.13.2 rel-0.8.4 rel-0.9 rel-0.9.1 rel-1.0.0 rel-1.1.0 rel-1.2.0 rel-1.2.1 rel-2.0.0 rel-2.1.0 rel-2.2.0 From bussonniermatthias at gmail.com Wed Sep 24 05:33:10 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Wed, 24 Sep 2014 11:33:10 +0200 Subject: [IPython-dev] git describe doesn't work? In-Reply-To: References: Message-ID: Le 24 sept. 2014 ? 11:06, Dave Hirschfeld a ?crit : > I've observed that git describe doesn't seem to work properly with the > ipython repo which makes my conda dev builds have the wrong version > number. What do you mean by do not work properly ? The things that you show below seem reasonable. -- M > > Not sure there is anything that can be done, but in case there is, it > would be nice to have git describe working. > > Thanks, > Dave > > > C:\dev\code\ipython [master...origin/master]> git describe --tags -- > dirty > rel-2.0.0-1644-ga2e1c67 > > C:\dev\code\ipython [master...origin/master]> git tag -l > dev-0.11 > rel-0.10 > rel-0.10.1 > rel-0.10.2 > rel-0.11 > rel-0.12 > rel-0.12.1 > rel-0.13 > rel-0.13.1 > rel-0.13.2 > rel-0.8.4 > rel-0.9 > rel-0.9.1 > rel-1.0.0 > rel-1.1.0 > rel-1.2.0 > rel-1.2.1 > rel-2.0.0 > rel-2.1.0 > rel-2.2.0 > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From bussonniermatthias at gmail.com Wed Sep 24 05:33:10 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Wed, 24 Sep 2014 11:33:10 +0200 Subject: [IPython-dev] git describe doesn't work? In-Reply-To: References: Message-ID: Le 24 sept. 2014 ? 11:06, Dave Hirschfeld a ?crit : > I've observed that git describe doesn't seem to work properly with the > ipython repo which makes my conda dev builds have the wrong version > number. What do you mean by do not work properly ? The things that you show below seem reasonable. -- M > > Not sure there is anything that can be done, but in case there is, it > would be nice to have git describe working. > > Thanks, > Dave > > > C:\dev\code\ipython [master...origin/master]> git describe --tags -- > dirty > rel-2.0.0-1644-ga2e1c67 > > C:\dev\code\ipython [master...origin/master]> git tag -l > dev-0.11 > rel-0.10 > rel-0.10.1 > rel-0.10.2 > rel-0.11 > rel-0.12 > rel-0.12.1 > rel-0.13 > rel-0.13.1 > rel-0.13.2 > rel-0.8.4 > rel-0.9 > rel-0.9.1 > rel-1.0.0 > rel-1.1.0 > rel-1.2.0 > rel-1.2.1 > rel-2.0.0 > rel-2.1.0 > rel-2.2.0 > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From jabooth at gmail.com Wed Sep 24 05:35:30 2014 From: jabooth at gmail.com (James Booth) Date: Wed, 24 Sep 2014 10:35:30 +0100 Subject: [IPython-dev] git describe doesn't work? In-Reply-To: References: Message-ID: Very strange timing, just this minute I am trying to diagnose a similar conda/git describe problem on our project menpo. This seems like a pretty clear case of the git history just not being there though: > git merge-base --is-ancestor rel-2.2.0 origin/master; echo $? 1 (false) > git merge-base --is-ancestor rel-2.1.0 origin/master; echo $? 1 (false) > git merge-base --is-ancestor rel-2.0.0 origin/master; echo $? 0 (true) The commits which have been tagged as the last two releases (2.2.0, 2.1.0) are not ancestors of master, hence it's description as 'a lot more commits than rel-2.0.0'. Don't know enough about IPython releases to know whether than is intentional or not though! Best James On 24 September 2014 10:33, Matthias Bussonnier < bussonniermatthias at gmail.com> wrote: > > Le 24 sept. 2014 ? 11:06, Dave Hirschfeld a ?crit : > > > I've observed that git describe doesn't seem to work properly with the > > ipython repo which makes my conda dev builds have the wrong version > > number. > > What do you mean by do not work properly ? > The things that you show below seem reasonable. > -- > M > > > > > Not sure there is anything that can be done, but in case there is, it > > would be nice to have git describe working. > > > > Thanks, > > Dave > > > > > > C:\dev\code\ipython [master...origin/master]> git describe --tags -- > > dirty > > rel-2.0.0-1644-ga2e1c67 > > > > C:\dev\code\ipython [master...origin/master]> git tag -l > > dev-0.11 > > rel-0.10 > > rel-0.10.1 > > rel-0.10.2 > > rel-0.11 > > rel-0.12 > > rel-0.12.1 > > rel-0.13 > > rel-0.13.1 > > rel-0.13.2 > > rel-0.8.4 > > rel-0.9 > > rel-0.9.1 > > rel-1.0.0 > > rel-1.1.0 > > rel-1.2.0 > > rel-1.2.1 > > rel-2.0.0 > > rel-2.1.0 > > rel-2.2.0 > > > > > > > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: From jabooth at gmail.com Wed Sep 24 05:35:30 2014 From: jabooth at gmail.com (James Booth) Date: Wed, 24 Sep 2014 10:35:30 +0100 Subject: [IPython-dev] git describe doesn't work? In-Reply-To: References: Message-ID: Very strange timing, just this minute I am trying to diagnose a similar conda/git describe problem on our project menpo. This seems like a pretty clear case of the git history just not being there though: > git merge-base --is-ancestor rel-2.2.0 origin/master; echo $? 1 (false) > git merge-base --is-ancestor rel-2.1.0 origin/master; echo $? 1 (false) > git merge-base --is-ancestor rel-2.0.0 origin/master; echo $? 0 (true) The commits which have been tagged as the last two releases (2.2.0, 2.1.0) are not ancestors of master, hence it's description as 'a lot more commits than rel-2.0.0'. Don't know enough about IPython releases to know whether than is intentional or not though! Best James On 24 September 2014 10:33, Matthias Bussonnier < bussonniermatthias at gmail.com> wrote: > > Le 24 sept. 2014 ? 11:06, Dave Hirschfeld a ?crit : > > > I've observed that git describe doesn't seem to work properly with the > > ipython repo which makes my conda dev builds have the wrong version > > number. > > What do you mean by do not work properly ? > The things that you show below seem reasonable. > -- > M > > > > > Not sure there is anything that can be done, but in case there is, it > > would be nice to have git describe working. > > > > Thanks, > > Dave > > > > > > C:\dev\code\ipython [master...origin/master]> git describe --tags -- > > dirty > > rel-2.0.0-1644-ga2e1c67 > > > > C:\dev\code\ipython [master...origin/master]> git tag -l > > dev-0.11 > > rel-0.10 > > rel-0.10.1 > > rel-0.10.2 > > rel-0.11 > > rel-0.12 > > rel-0.12.1 > > rel-0.13 > > rel-0.13.1 > > rel-0.13.2 > > rel-0.8.4 > > rel-0.9 > > rel-0.9.1 > > rel-1.0.0 > > rel-1.1.0 > > rel-1.2.0 > > rel-1.2.1 > > rel-2.0.0 > > rel-2.1.0 > > rel-2.2.0 > > > > > > > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: From bussonniermatthias at gmail.com Wed Sep 24 05:47:13 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Wed, 24 Sep 2014 11:47:13 +0200 Subject: [IPython-dev] Issues with shell commands in IPython Notebook (Windows version) In-Reply-To: References: Message-ID: Hi, !, is a shortcut for the magic %sx that in the end wrap subprocess, if you want to track down : IPython.core.interactiveshell:system IPython.utils.process:getoutput IPython.utils._process_common:process_handle p = subprocess.Popen(cmd, shell=isinstance(cmd, py3compat.string_types), stdin=subprocess.PIPE, stdout=subprocess.PIPE, stderr=stderr, close_fds=close_fds) The limitation are the limitation of subprocess, and the limitation of user testing and developing on windows. History can show you that not many windows de/user did care about this, and with no windows machine its hard to help. https://github.com/ipython/ipython/commits/master/IPython/utils/_process_common.py If you can try with Popen directly, and make it to work we can probably adapt the logic. -- M Le 24 sept. 2014 ? 10:48, Kenneth Tran a ?crit : > I have 2 instances of IPython NBServer running, one runs on Linux and the other runs on Windows. Let's call them NB-Win and NB-Linux. On both machines, IPython was installed using Anaconda. > > The experience of calling shell commands on NB-Win has been terrible. Many commands hang for no reason. > > I've tried > !wget http://www.csie.ntu.edu.tw/~cjlin/libsvmtools/datasets/binary/kddb.t.bz2 > (which is just 25MB) in a notebook on both servers. > > On NB-Win > The command always failed to terminate. It hangs like this forever > > > > When I looked at the wget process in Process Explorer, none of the numbers (CPU, memory, IO, network, etc.) moved. If I killed the process, then now the cell returned something, like this > > > > The experience is the same with other commands. For example, I tried going to a directory and calling !make, and that one also didn't terminate. > > For comparison, this is what looks like when I run the same command using NB-Linux. The output is displayed as the program is running and the program exits in a few seconds. > > > So my questions are > Why does the above command above (as well as many others) hang in NB-Win? (I could replicate this issue easily on my other Windows machines.) > Why can't NB-Win display console output in real-time as the program is running? While both NB-Linux and IPython shell on Windows/Linux can. > Why does NB-Win display a different output (or error?) string than what IPython-Win shell (on the same machine) produces? Both invoke the same C:\Cygwin\bin\wget.exe command line. > > > Those issues have driven me crazy. I would appreciate any help. > > -Ken > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: From bussonniermatthias at gmail.com Wed Sep 24 05:49:21 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Wed, 24 Sep 2014 11:49:21 +0200 Subject: [IPython-dev] git describe doesn't work? In-Reply-To: References: Message-ID: <7928F684-BBA3-4763-AD64-AFDF6F530A2F@gmail.com> Le 24 sept. 2014 ? 11:35, James Booth a ?crit : > Very strange timing, just this minute I am trying to diagnose a similar conda/git describe problem on our project menpo. > > This seems like a pretty clear case of the git history just not being there though: > > > git merge-base --is-ancestor rel-2.2.0 origin/master; echo $? > 1 (false) > > > git merge-base --is-ancestor rel-2.1.0 origin/master; echo $? > 1 (false) > > > git merge-base --is-ancestor rel-2.0.0 origin/master; echo $? > 0 (true) > > The commits which have been tagged as the last two releases (2.2.0, 2.1.0) are not ancestors of master, hence it's description as 'a lot more commits than rel-2.0.0'. Don't know enough about IPython releases to know whether than is intentional or not though! Ah ! Yes, 2.0 has two children branches. 2.x and master. 2.x have tags 2.1 and 2.2 (soon 2.3) master is child of 2.0.0. Having master child of 2.0 would imply rebasing master :-P -- M > > Best > James > > > On 24 September 2014 10:33, Matthias Bussonnier wrote: > > Le 24 sept. 2014 ? 11:06, Dave Hirschfeld a ?crit : > > > I've observed that git describe doesn't seem to work properly with the > > ipython repo which makes my conda dev builds have the wrong version > > number. > > What do you mean by do not work properly ? > The things that you show below seem reasonable. > -- > M > > > > > Not sure there is anything that can be done, but in case there is, it > > would be nice to have git describe working. > > > > Thanks, > > Dave > > > > > > C:\dev\code\ipython [master...origin/master]> git describe --tags -- > > dirty > > rel-2.0.0-1644-ga2e1c67 > > > > C:\dev\code\ipython [master...origin/master]> git tag -l > > dev-0.11 > > rel-0.10 > > rel-0.10.1 > > rel-0.10.2 > > rel-0.11 > > rel-0.12 > > rel-0.12.1 > > rel-0.13 > > rel-0.13.1 > > rel-0.13.2 > > rel-0.8.4 > > rel-0.9 > > rel-0.9.1 > > rel-1.0.0 > > rel-1.1.0 > > rel-1.2.0 > > rel-1.2.1 > > rel-2.0.0 > > rel-2.1.0 > > rel-2.2.0 > > > > > > > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: From bussonniermatthias at gmail.com Wed Sep 24 05:49:21 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Wed, 24 Sep 2014 11:49:21 +0200 Subject: [IPython-dev] git describe doesn't work? In-Reply-To: References: Message-ID: <7928F684-BBA3-4763-AD64-AFDF6F530A2F@gmail.com> Le 24 sept. 2014 ? 11:35, James Booth a ?crit : > Very strange timing, just this minute I am trying to diagnose a similar conda/git describe problem on our project menpo. > > This seems like a pretty clear case of the git history just not being there though: > > > git merge-base --is-ancestor rel-2.2.0 origin/master; echo $? > 1 (false) > > > git merge-base --is-ancestor rel-2.1.0 origin/master; echo $? > 1 (false) > > > git merge-base --is-ancestor rel-2.0.0 origin/master; echo $? > 0 (true) > > The commits which have been tagged as the last two releases (2.2.0, 2.1.0) are not ancestors of master, hence it's description as 'a lot more commits than rel-2.0.0'. Don't know enough about IPython releases to know whether than is intentional or not though! Ah ! Yes, 2.0 has two children branches. 2.x and master. 2.x have tags 2.1 and 2.2 (soon 2.3) master is child of 2.0.0. Having master child of 2.0 would imply rebasing master :-P -- M > > Best > James > > > On 24 September 2014 10:33, Matthias Bussonnier wrote: > > Le 24 sept. 2014 ? 11:06, Dave Hirschfeld a ?crit : > > > I've observed that git describe doesn't seem to work properly with the > > ipython repo which makes my conda dev builds have the wrong version > > number. > > What do you mean by do not work properly ? > The things that you show below seem reasonable. > -- > M > > > > > Not sure there is anything that can be done, but in case there is, it > > would be nice to have git describe working. > > > > Thanks, > > Dave > > > > > > C:\dev\code\ipython [master...origin/master]> git describe --tags -- > > dirty > > rel-2.0.0-1644-ga2e1c67 > > > > C:\dev\code\ipython [master...origin/master]> git tag -l > > dev-0.11 > > rel-0.10 > > rel-0.10.1 > > rel-0.10.2 > > rel-0.11 > > rel-0.12 > > rel-0.12.1 > > rel-0.13 > > rel-0.13.1 > > rel-0.13.2 > > rel-0.8.4 > > rel-0.9 > > rel-0.9.1 > > rel-1.0.0 > > rel-1.1.0 > > rel-1.2.0 > > rel-1.2.1 > > rel-2.0.0 > > rel-2.1.0 > > rel-2.2.0 > > > > > > > > _______________________________________________ > > IPython-dev mailing list > > IPython-dev at scipy.org > > http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: From dave.hirschfeld at gmail.com Wed Sep 24 05:48:19 2014 From: dave.hirschfeld at gmail.com (Dave Hirschfeld) Date: Wed, 24 Sep 2014 09:48:19 +0000 (UTC) Subject: [IPython-dev] git describe doesn't work? References: Message-ID: Matthias Bussonnier gmail.com> writes: > > > Le 24 sept. 2014 ? 11:06, Dave Hirschfeld a ?crit : > > > I've observed that git describe doesn't seem to work properly with the > > ipython repo which makes my conda dev builds have the wrong version > > number. > > What do you mean by do not work properly ? > The things that you show below seem reasonable. As shown, git describe says the tip of master is 1644 commits on from release *2.0.0* which is all well and good, but what you really want to know is how far from the *latest* release you are. This is important, because using the output from git describe will result in the latest master (rel-2.0.0-1644-ga2e1c67) comparing less than the last release (rel-2.2.0) which is obviously not what you want. In [5]: verlib.NormalizedVersion('2.0.0.1644') > verlib.NormalizedVersion('2.2.0') Out[5]: False It seems James has tracked down the source of the problem, so if it's not intentional that releases aren't ancestors of master it would be nice to ensure they are going forward IMHO -Dave From bussonniermatthias at gmail.com Wed Sep 24 06:09:11 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Wed, 24 Sep 2014 12:09:11 +0200 Subject: [IPython-dev] git describe doesn't work? In-Reply-To: References: Message-ID: <8BECE779-103F-41B2-AF9E-B6D0D8D93CDC@gmail.com> Le 24 sept. 2014 ? 11:48, Dave Hirschfeld a ?crit : > Matthias Bussonnier gmail.com> writes: > >> >> >> Le 24 sept. 2014 ? 11:06, Dave Hirschfeld a ?crit : >> >>> I've observed that git describe doesn't seem to work properly with > the >>> ipython repo which makes my conda dev builds have the wrong version >>> number. >> >> What do you mean by do not work properly ? >> The things that you show below seem reasonable. > > As shown, git describe says the tip of master is 1644 commits on from > release *2.0.0* which is all well and good, but what you really want to > know is how far from the *latest* release you are. > > > This is important, because using the output from git describe will > result in the latest master (rel-2.0.0-1644-ga2e1c67) comparing less > than the last release (rel-2.2.0) which is obviously not what you want. But the patches that are applied to 2.x and master are different. 2.x cannot really be considered be considers as in between 2.0 and master. its like saying that obviously 7.5+0.001im is the middle of 5.0 and 10.0. Though I understand what you want to do. Would tagging the 2.0.0+1commit to something like 3.0.0-dev suit you ? You would still not have 2.1 and 2.2 ancestor of 3.0.0-dev, but it should be simpler for comparison. -- M > > In [5]: verlib.NormalizedVersion('2.0.0.1644') > > verlib.NormalizedVersion('2.2.0') > Out[5]: False > > It seems James has tracked down the source of the problem, so if it's > not intentional that releases aren't ancestors of master it would be > nice to ensure they are going forward IMHO > > -Dave > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From bussonniermatthias at gmail.com Wed Sep 24 06:09:11 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Wed, 24 Sep 2014 12:09:11 +0200 Subject: [IPython-dev] git describe doesn't work? In-Reply-To: References: Message-ID: <8BECE779-103F-41B2-AF9E-B6D0D8D93CDC@gmail.com> Le 24 sept. 2014 ? 11:48, Dave Hirschfeld a ?crit : > Matthias Bussonnier gmail.com> writes: > >> >> >> Le 24 sept. 2014 ? 11:06, Dave Hirschfeld a ?crit : >> >>> I've observed that git describe doesn't seem to work properly with > the >>> ipython repo which makes my conda dev builds have the wrong version >>> number. >> >> What do you mean by do not work properly ? >> The things that you show below seem reasonable. > > As shown, git describe says the tip of master is 1644 commits on from > release *2.0.0* which is all well and good, but what you really want to > know is how far from the *latest* release you are. > > > This is important, because using the output from git describe will > result in the latest master (rel-2.0.0-1644-ga2e1c67) comparing less > than the last release (rel-2.2.0) which is obviously not what you want. But the patches that are applied to 2.x and master are different. 2.x cannot really be considered be considers as in between 2.0 and master. its like saying that obviously 7.5+0.001im is the middle of 5.0 and 10.0. Though I understand what you want to do. Would tagging the 2.0.0+1commit to something like 3.0.0-dev suit you ? You would still not have 2.1 and 2.2 ancestor of 3.0.0-dev, but it should be simpler for comparison. -- M > > In [5]: verlib.NormalizedVersion('2.0.0.1644') > > verlib.NormalizedVersion('2.2.0') > Out[5]: False > > It seems James has tracked down the source of the problem, so if it's > not intentional that releases aren't ancestors of master it would be > nice to ensure they are going forward IMHO > > -Dave > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev From dave.hirschfeld at gmail.com Wed Sep 24 06:12:45 2014 From: dave.hirschfeld at gmail.com (Dave Hirschfeld) Date: Wed, 24 Sep 2014 10:12:45 +0000 (UTC) Subject: [IPython-dev] git describe doesn't work? References: <8BECE779-103F-41B2-AF9E-B6D0D8D93CDC@gmail.com> Message-ID: Matthias Bussonnier gmail.com> writes: > > But the patches that are applied to 2.x and master are different. > > 2.x cannot really be considered be considers as in between 2.0 and master. > > its like saying that obviously 7.5+0.001im is the middle of 5.0 and 10.0. > > Though I understand what you want to do. > Would tagging the 2.0.0+1commit to something like 3.0.0-dev suit you ? > > You would still not have 2.1 and 2.2 ancestor of 3.0.0-dev, but it should be simpler for comparison. > The explanation does make sense. I like your idea of tagging 3.0.0-dev as I think that will solve the problem of (git describe) master comparing less than release 2.2.0. Thanks, Dave From gustavo.goretkin at gmail.com Wed Sep 24 08:27:47 2014 From: gustavo.goretkin at gmail.com (Gustavo Goretkin) Date: Wed, 24 Sep 2014 08:27:47 -0400 Subject: [IPython-dev] Real-time console output in notebooks In-Reply-To: References: Message-ID: I have used the following approach in a notebook before: http://stackoverflow.com/questions/4620547/real-time-output-of-subprocess-popen-and-not-line-by-line On Wed, Sep 24, 2014 at 2:06 AM, Kenneth Tran wrote: > Is it possible to see real-time output of a system command? It seems that > while IPython shows real-time output, IPython notebook doesn't. Or am I > doing anything wrong? > > Which leads to another point. I recently tried to compile with !bang in a > notebook. It got hang indefinitely. > > Then I ssh to the machine and do the same thing (cd to a directory and > call make) and this one finished rather quickly, albeit with some errors. > > Is there any explanation for why the command in the notebook didn't > terminate? > > Thanks. > -Ken > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From takowl at gmail.com Wed Sep 24 13:48:40 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Wed, 24 Sep 2014 10:48:40 -0700 Subject: [IPython-dev] Real-time console output in notebooks In-Reply-To: References: Message-ID: I see real time output if I put the text below in a file and run !bash slowloop.sh for i in `seq 1 10`; do sleep 1 echo $i done On 23 September 2014 23:06, Kenneth Tran wrote: > Is it possible to see real-time output of a system command? It seems that > while IPython shows real-time output, IPython notebook doesn't. Or am I > doing anything wrong? > > Which leads to another point. I recently tried to compile with !bang in a > notebook. It got hang indefinitely. > > Then I ssh to the machine and do the same thing (cd to a directory and > call make) and this one finished rather quickly, albeit with some errors. > > Is there any explanation for why the command in the notebook didn't > terminate? > > Thanks. > -Ken > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From fperez.net at gmail.com Wed Sep 24 13:54:43 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Wed, 24 Sep 2014 10:54:43 -0700 Subject: [IPython-dev] Issues with shell commands in IPython Notebook (Windows version) In-Reply-To: References: Message-ID: On Wed, Sep 24, 2014 at 1:48 AM, Kenneth Tran wrote: > The experience of calling shell commands on NB-Win has been terrible. Many > commands hang for no reason. As Matthias indicated, unfortunately the core team has fairly limited expertise on Windows, except for Jorgen Stenarson. He has done great work on the project, but he is also bandwidth constrained and I'm sure would appreciate the help. If you can contribute fixes to our Windows support, we'd be very happy to review them and incorporate them, as we obviously want all of IPython to work as well as possible on Windows. But lacking that expertise and dialy use ourselves, the fixes will likely not come from us, I'm afraid. Hopefully this will be seen as an *opportunity* for all Windows users out there: you can really help the IPython project in a way that will make a significant difference for many, by contributing to our Windows support. Join the team and help us on this front! Cheers, f -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: From takowl at gmail.com Wed Sep 24 13:57:48 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Wed, 24 Sep 2014 10:57:48 -0700 Subject: [IPython-dev] Issues with shell commands in IPython Notebook (Windows version) In-Reply-To: References: Message-ID: I think I see it. See IPython.utils._process_win32._system_body(). It will read all of stdout, and then all of stderr. If a process is writing a lot to stderr (as it looks like wget is), it will fill up a buffer, then hang, because we're still trying to read stdout. We could use Popen.communicate() for this, though that's still not going to get you output updating in real time. Trying to do real time output properly might be more tricky. Thomas On 24 September 2014 02:47, Matthias Bussonnier < bussonniermatthias at gmail.com> wrote: > Hi, > > !, is a shortcut for the magic %sx that in the end wrap subprocess, if you > want to track down : > > IPython.core.interactiveshell:system > IPython.utils.process:getoutput > IPython.utils._process_common:process_handle > > p = subprocess.Popen(cmd, shell=isinstance(cmd, py3compat.string_types), > stdin=subprocess.PIPE, > stdout=subprocess.PIPE, > stderr=stderr, > close_fds=close_fds) > > The limitation are the limitation of subprocess, and the limitation of > user testing and developing on windows. > History can show you that not many windows de/user did care about this, > and with no windows machine its hard to help. > > > https://github.com/ipython/ipython/commits/master/IPython/utils/_process_common.py > > If you can try with Popen directly, and make it to work we can probably > adapt the logic. > -- > M > > > > Le 24 sept. 2014 ? 10:48, Kenneth Tran a ?crit : > > I have 2 instances of IPython NBServer running, one runs on Linux and the > other runs on Windows. Let's call them NB-Win and NB-Linux. On both > machines, IPython was installed using Anaconda. > > The experience of calling shell commands on NB-Win has been terrible. Many > commands hang for no reason. > > I've tried > > *!wget > http://www.csie.ntu.edu.tw/~cjlin/libsvmtools/datasets/binary/kddb.t.bz2 > * > > (which is just 25MB) in a notebook on both servers. > > *On NB-Win* > The command always failed to terminate. It hangs like this forever > > > > When I looked at the *wget* process in Process Explorer, none of the > numbers (CPU, memory, IO, network, etc.) moved. If I killed the process, > then now the cell returned something, like this > > > > The experience is the same with other commands. For example, I tried going > to a directory and calling *!make*, and that one also didn't terminate. > > For comparison, this is what looks like when I run the same command > using NB-Linux. The output is displayed as the program is running and the > program exits in a few seconds. > > > *So my questions are* > > 1. Why does the above command above (as well as many others) hang in > NB-Win? (I could replicate this issue easily on my other Windows machines.) > 2. Why can't NB-Win display console output in real-time as the program > is running? While both NB-Linux and IPython shell on Windows/Linux can. > 3. Why does NB-Win display a different output (or error?) string than > what IPython-Win shell (on the same machine) produces? Both invoke the same > *C:\Cygwin\bin\wget.exe* command line. > > > > > Those issues have driven me crazy. I would appreciate any help. > > -Ken > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From gustavo.goretkin at gmail.com Thu Sep 25 02:31:32 2014 From: gustavo.goretkin at gmail.com (Gustavo Goretkin) Date: Thu, 25 Sep 2014 02:31:32 -0400 Subject: [IPython-dev] IPython inputhook, higher rate? In-Reply-To: References: Message-ID: I'm looking to investigate this but I'm confused about some important things CPython calls the inputhook at 10Hz according to [1]. You can verify this with [2], so my issue isn't related to SDL or pygame. It's just that the callback gets called infrequently. How then am I able to manipulate my matplotlib window and type more than 10 characters a second into the interpreter prompt? According to import threading; threading.enumerate(), there are no threads aside from the "_MainThread" and "HistorySavingThread", so I think some threads are being setup and run from the gui libraries (like wx). I guess I do not understand what is meant in [3]. [1] http://benno.id.au/blog/2006/09/02/pyton_rfte [2] https://gist.github.com/goretkin/1973cb3735d03b04cc95 [3] http://ipython.org/ipython-doc/rel-0.11/interactive/reference.html#gui-support On Tue, Sep 9, 2014 at 1:07 PM, Fernando Perez wrote: > On Tue, Sep 9, 2014 at 10:03 AM, Erik Bray wrote: > >> My guess is that an inputhook handler for SDL similar to the pyglet >> inputhook might be necessary: >> >> >> https://github.com/ipython/ipython/blob/825f3e480e9d9e4032abab7bc72e5cd086cc3e89/IPython/lib/inputhookpyglet.py >> > > Yup, good guess. I suspect the solution is along those lines too. > > >> I don't have any more time too look into it right now though. >> > > Sadly, most of us in the core team are in the same boat. If someone can > put together a well-tested PR that solves the problem for them, we can > probably merge it relatively quickly. These things are typically a small > amount of code, but they require patience to get right and lots of live, > interactive testing. We can't do that right now on this topic, but a clean > PR where someone has done all that leg work would likely not be too hard to > merge. > > Cheers, > > f > > > -- > Fernando Perez (@fperez_org; http://fperez.org) > fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) > fernando.perez-at-berkeley: contact me here for any direct mail > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From erik.m.bray at gmail.com Thu Sep 25 11:17:00 2014 From: erik.m.bray at gmail.com (Erik Bray) Date: Thu, 25 Sep 2014 11:17:00 -0400 Subject: [IPython-dev] IPython inputhook, higher rate? In-Reply-To: References: Message-ID: On Thu, Sep 25, 2014 at 2:31 AM, Gustavo Goretkin wrote: > I'm looking to investigate this but I'm confused about some important things > > CPython calls the inputhook at 10Hz according to [1]. You can verify this > with [2], so my issue isn't related to SDL or pygame. It's just that the > callback gets called infrequently. > > How then am I able to manipulate my matplotlib window and type more than 10 > characters a second into the interpreter prompt? According to import > threading; threading.enumerate(), there are no threads aside from the > "_MainThread" and "HistorySavingThread", so I think some threads are being > setup and run from the gui libraries (like wx). I guess I do not understand > what is meant in [3]. Good questions-- speaking of matplotlib as an example, on my system when I run Python in interactive mode the default backend for matplotlib is TKAgg, and hence is using TK for the graphical display/event handling. So the place to look is the tkinter module's own InputHook handler. In short, it basically sets up its own select() loop that processing TCL events (each followed by a sleep, adjustable by _tkinter.setbusywaitinterval --the default is 20 ms) which runs until input is ready on stdin (at which point it returns control to Python). This is separate from the normal main event loop in that it *can* return control without quitting. If you look, for example, at IPython's inputhook handler for pyglet [1] you can see it does something pretty similar to what I just described. So something similar is needed that will be compatible with pygame -- or pysdl more generally. Hope that helps! Erik [1] https://github.com/ipython/ipython/blob/master/IPython/lib/inputhookpyglet.py > On Tue, Sep 9, 2014 at 1:07 PM, Fernando Perez wrote: >> >> On Tue, Sep 9, 2014 at 10:03 AM, Erik Bray wrote: >>> >>> My guess is that an inputhook handler for SDL similar to the pyglet >>> inputhook might be necessary: >>> >>> >>> https://github.com/ipython/ipython/blob/825f3e480e9d9e4032abab7bc72e5cd086cc3e89/IPython/lib/inputhookpyglet.py >> >> >> Yup, good guess. I suspect the solution is along those lines too. >> >>> >>> I don't have any more time too look into it right now though. >> >> >> Sadly, most of us in the core team are in the same boat. If someone can >> put together a well-tested PR that solves the problem for them, we can >> probably merge it relatively quickly. These things are typically a small >> amount of code, but they require patience to get right and lots of live, >> interactive testing. We can't do that right now on this topic, but a clean >> PR where someone has done all that leg work would likely not be too hard to >> merge. >> >> Cheers, >> >> f >> >> >> -- >> Fernando Perez (@fperez_org; http://fperez.org) >> fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) >> fernando.perez-at-berkeley: contact me here for any direct mail >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > From takowl at gmail.com Thu Sep 25 12:20:39 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Thu, 25 Sep 2014 09:20:39 -0700 Subject: [IPython-dev] IPython inputhook, higher rate? In-Reply-To: References: Message-ID: On 25 September 2014 08:17, Erik Bray wrote: > In short, it basically sets up its own select() loop that processing > TCL events (each followed by a sleep, adjustable by > _tkinter.setbusywaitinterval --the default is 20 ms) which runs until > input is ready on stdin (at which point it returns control to Python). > This is separate from the normal main event loop in that it *can* > return control without quitting. > Yep - as Erik points out, several of our own input hooks do this: instead of relying on Python polling PyOS_InputHook, they seize control and keep running their own event loop until there's data ready on stdin, then return control to Python. We provide a stdin_ready() function to facilitate this. I've actually just written some documentation for integrating event loops with IPython. You can see it here: http://ipython.org/ipython-doc/dev/config/eventloops.html Some of the APIs it describes are new in master, but the way that event loop integration works hasn't changed. Thomas -------------- next part -------------- An HTML attachment was scrubbed... URL: From Andy at SantaCruzIntegration.com Thu Sep 25 20:04:34 2014 From: Andy at SantaCruzIntegration.com (Andy Davidson) Date: Thu, 25 Sep 2014 17:04:34 -0700 Subject: [IPython-dev] how to upgrade iPython on AWS ec2? ERROR: Line magic function `%matplotlib` not found. Message-ID: Hi I am new to AWS.amazon and ec2. When I run my iPython notebook I get the error ERROR: Line magic function `%matplotlib` not found. import IPython print IPython.sys_info() {'commit_hash': '858d539', 'commit_source': 'installation', 'default_encoding': 'UTF-8', 'ipython_path': '/usr/lib/python2.6/site-packages/ipython-0.13.2-py2.6.egg/IPython', 'ipython_version': '0.13.2', 'os_name': 'posix', 'platform': 'Linux-3.4.37-40.44.amzn1.x86_64-x86_64-with-glibc2.2.5', 'sys_executable': '/usr/bin/python2.6', 'sys_platform': 'linux2', 'sys_version': '2.6.8 (unknown, Mar 14 2013, 09:31:22) \n[GCC 4.6.2 20111027 (Red Hat 4.6.2-2)]'} This notebook works fine on my mac {'commit_hash': '681fd77', 'commit_source': 'installation', 'default_encoding': 'UTF-8', 'ipython_path': '/Library/Python/2.7/site-packages/IPython', 'ipython_version': '2.1.0', 'os_name': 'posix', 'platform': 'Darwin-13.3.0-x86_64-i386-64bit', 'sys_executable': '/usr/bin/python', 'sys_platform': 'darwin', 'sys_version': '2.7.5 (default, Mar 9 2014, 22:15:05) \n[GCC 4.2.1 Compatible Apple LLVM 5.0 (clang-500.0.68)]?} I am new to red hat. Any idea how you upgrade to version 2.1.0 ? I found a link that suggested I do the following yum -y install python-pip # I have not idea what version I am going to wind up with I to use the same version as my mac ?2.1.0' pip install --upgrade ipython This failed because my python version was 2.6 and it needs to be at least 2.7 I found this link how ever I find it hard to believe I have to down load the source for python first and compile it http://stackoverflow.com/questions/6630873/how-to-download-python-from-comma nd-line Any suggestions? Thanks Andy -------------- next part -------------- An HTML attachment was scrubbed... URL: From takowl at gmail.com Thu Sep 25 20:48:23 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Thu, 25 Sep 2014 17:48:23 -0700 Subject: [IPython-dev] how to upgrade iPython on AWS ec2? ERROR: Line magic function `%matplotlib` not found. In-Reply-To: References: Message-ID: Hi Andy, You should be able to upgrade to IPython 1.2.1 on Python 2.6, and I believe that has the %matplotlib magic. Red hat is a very conservative Linux distro, which is why it still offers Python 2.6. If that's not what you want, I'd use the Ubuntu LTS images, which will definitely have Python 2.7. Thomas On 25 September 2014 17:04, Andy Davidson wrote: > Hi > > I am new to AWS.amazon and ec2. When I run my iPython notebook I get the > error > > ERROR: Line magic function `%matplotlib` not found. > > import IPython > print IPython.sys_info() > > {'commit_hash': '858d539', > 'commit_source': 'installation', > 'default_encoding': 'UTF-8', > 'ipython_path': '/usr/lib/python2.6/site-packages/ipython-0.13.2-py2.6.egg/IPython', > 'ipython_version': '0.13.2', > 'os_name': 'posix', > 'platform': 'Linux-3.4.37-40.44.amzn1.x86_64-x86_64-with-glibc2.2.5', > 'sys_executable': '/usr/bin/python2.6', > 'sys_platform': 'linux2', > 'sys_version': '2.6.8 (unknown, Mar 14 2013, 09:31:22) \n[GCC 4.6.2 20111027 (Red Hat 4.6.2-2)]'} > > This notebook works fine on my mac > > {'commit_hash': '681fd77', > 'commit_source': 'installation', > 'default_encoding': 'UTF-8', > 'ipython_path': '/Library/Python/2.7/site-packages/IPython', > 'ipython_version': '2.1.0', > 'os_name': 'posix', > 'platform': 'Darwin-13.3.0-x86_64-i386-64bit', > 'sys_executable': '/usr/bin/python', > 'sys_platform': 'darwin', > 'sys_version': '2.7.5 (default, Mar 9 2014, 22:15:05) \n[GCC 4.2.1 Compatible Apple LLVM 5.0 (clang-500.0.68)]?} > > > I am new to red hat. Any idea how you upgrade to version 2.1.0 ? > > > I found a link that suggested I do the following > > yum -y install python-pip > > > # I have not idea what version I am going to wind up with I to use the > same version as my mac ?2.1.0' > > pip install --upgrade ipython > > > This failed because my python version was 2.6 and it needs to be at least > 2.7 > > > I found this link how ever I find it hard to believe I have to down load the source for python first and compile it > > http://stackoverflow.com/questions/6630873/how-to-download-python-from-command-line > > > > > Any suggestions? > > > Thanks > > > Andy > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From somada141 at gmail.com Sat Sep 27 04:33:10 2014 From: somada141 at gmail.com (Adamos Kyriakou) Date: Sat, 27 Sep 2014 18:33:10 +1000 Subject: [IPython-dev] Embed IPython console into a web-app GUI Message-ID: Hi all, I?ve been searching for a while for a way to embed an IPython terminal into a web-app GUI, in particular one created with Muntjac (a pythonic version of Vaadin), but to no avail. While there?s tons of material on how to embed it in Qt/wx/Tk applications and the like, I haven?t found a decent solution for a web-app. On the other hand I?m confident it?s possible as the guys at PythonAnywhere and Wakari have pulled it off. Any ideas on how this could be achieved? Thanks a bunch! PS. As you can see this question has been asked a number of times on different platforms but without a definitive answer: http://mail.scipy.org/pipermail/ipython-dev/2013-October/012505.html http://stackoverflow.com/questions/11264918/how-to-embed-a-python-interpreter-on-a-website http://stackoverflow.com/questions/17014868/add-an-ipython-console-to-a-webpage -------------- next part -------------- An HTML attachment was scrubbed... URL: From takowl at gmail.com Sat Sep 27 14:34:45 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Sat, 27 Sep 2014 11:34:45 -0700 Subject: [IPython-dev] Embed IPython console into a web-app GUI In-Reply-To: References: Message-ID: Hi Adamos, There are two answers to this: First, you can embed a terminal emulator in your application, and run plain terminal IPython. This is what Pythonanywhere and Wakari do. The existing packages for this that I'm aware of to do this in Python - shellinabox and GateOne - are GPL and AGPL licensed respectively, so unfortunately we can't use them in IPython. As it happens, I'm currently working with R. Saravanan to clean up the BSD-licensed terminal emulator component of his Graphterm project. This provides a Python backend for the MIT-licensed term.js Javascript terminal emulator. If you're interested in this, I'm working on this in a branch here: https://github.com/takluyver/pyxterm/tree/teardown The second answer is to actually build a proper web console interface, reusing pieces from the IPython notebook machinery. This would be more work, but could provide a much nicer interface, because it's not constrained by the limitations of the tty interface, which was originally designed for computers to drive an electronic typewriter. We do want to get to this, because it would be useful to have such a console available in the notebook interface. I hope that's useful - feel free to ask if you have more questions. And thanks for the link to Muntjac, it looks like an interesting project. Best wishes, Thomas On 27 September 2014 01:33, Adamos Kyriakou wrote: > Hi all, > > I?ve been searching for a while for a way to embed an IPython terminal > into a web-app GUI, in particular one created with Muntjac > (a pythonic version of Vaadin > ), but to no avail. While there?s tons of material on how > to embed it in Qt/wx/Tk > applications > and the like, I haven?t found a decent solution for a web-app. On the other > hand I?m confident it?s possible as the guys at PythonAnywhere > and Wakari > have pulled it off. > > Any ideas on how this could be achieved? > > Thanks a bunch! > > PS. As you can see this question has been asked a number of times on > different platforms but without a definitive answer: > > http://mail.scipy.org/pipermail/ipython-dev/2013-October/012505.html > > http://stackoverflow.com/questions/11264918/how-to-embed-a-python-interpreter-on-a-website > > http://stackoverflow.com/questions/17014868/add-an-ipython-console-to-a-webpage > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From kikocorreoso at gmail.com Sat Sep 27 15:24:30 2014 From: kikocorreoso at gmail.com (Kiko) Date: Sat, 27 Sep 2014 21:24:30 +0200 Subject: [IPython-dev] Embed IPython console into a web-app GUI In-Reply-To: References: Message-ID: 2014-09-27 20:34 GMT+02:00 Thomas Kluyver : > Hi Adamos, > > There are two answers to this: > > First, you can embed a terminal emulator in your application, and run > plain terminal IPython. This is what Pythonanywhere and Wakari do. The > existing packages for this that I'm aware of to do this in Python - > shellinabox and GateOne - are GPL and AGPL licensed respectively, so > unfortunately we can't use them in IPython. As it happens, I'm currently > working with R. Saravanan to clean up the BSD-licensed terminal emulator > component of his Graphterm project. This provides a Python backend for the > MIT-licensed term.js Javascript terminal emulator. > > If you're interested in this, I'm working on this in a branch here: > https://github.com/takluyver/pyxterm/tree/teardown > > The second answer is to actually build a proper web console interface, > reusing pieces from the IPython notebook machinery. This would be more > work, but could provide a much nicer interface, because it's not > constrained by the limitations of the tty interface, which was originally > designed for computers to drive an electronic typewriter. We do want to get > to this, because it would be useful to have such a console available in the > notebook interface. > > I hope that's useful - feel free to ask if you have more questions. And > thanks for the link to Muntjac, it looks like an interesting project. > > Best wishes, > Thomas > > On 27 September 2014 01:33, Adamos Kyriakou wrote: > >> Hi all, >> >> I?ve been searching for a while for a way to embed an IPython terminal >> into a web-app GUI, in particular one created with Muntjac >> (a pythonic version of Vaadin >> ), but to no avail. While there?s tons of material >> on how to embed it in Qt/wx/Tk >> applications >> and the like, I haven?t found a decent solution for a web-app. On the other >> hand I?m confident it?s possible as the guys at PythonAnywhere >> and Wakari >> have pulled it off. >> > It is not IPython but maybe it could be useful for your use case: http://nbviewer.ipython.org/gist/anonymous/b86d66089a29ff2bef5e All is running on the client. > >> Any ideas on how this could be achieved? >> >> Thanks a bunch! >> >> PS. As you can see this question has been asked a number of times on >> different platforms but without a definitive answer: >> >> http://mail.scipy.org/pipermail/ipython-dev/2013-October/012505.html >> >> http://stackoverflow.com/questions/11264918/how-to-embed-a-python-interpreter-on-a-website >> >> http://stackoverflow.com/questions/17014868/add-an-ipython-console-to-a-webpage >> >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> >> > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -------------- next part -------------- An HTML attachment was scrubbed... URL: From wes.turner at gmail.com Sat Sep 27 16:02:14 2014 From: wes.turner at gmail.com (Wes Turner) Date: Sat, 27 Sep 2014 15:02:14 -0500 Subject: [IPython-dev] Embed IPython console into a web-app GUI In-Reply-To: References: Message-ID: There may be some useful resources in this presentation from PyCon 2014: "Jessica McKellar: Building and breaking a Python sandbox - PyCon 2014" * https://speakerdeck.com/pycon2014/building-and-breaking-a-python-sandbox-by-jessica-mckellar * https://www.youtube.com/watch?v=sL_syMmRkoU Depending on the type of deployment, there are nontrivial security challenges inherent to this problem: * https://github.com/jupyter/jupyterhub * https://github.com/jupyter/dockerspawner On Sat, Sep 27, 2014 at 3:33 AM, Adamos Kyriakou wrote: > Hi all, > > I?ve been searching for a while for a way to embed an IPython terminal into > a web-app GUI, in particular one created with Muntjac (a pythonic version of > Vaadin), but to no avail. While there?s tons of material on how to embed it > in Qt/wx/Tk applications and the like, I haven?t found a decent solution for > a web-app. On the other hand I?m confident it?s possible as the guys at > PythonAnywhere and Wakari have pulled it off. > > Any ideas on how this could be achieved? > > Thanks a bunch! > > PS. As you can see this question has been asked a number of times on > different platforms but without a definitive answer: > > http://mail.scipy.org/pipermail/ipython-dev/2013-October/012505.html > http://stackoverflow.com/questions/11264918/how-to-embed-a-python-interpreter-on-a-website > http://stackoverflow.com/questions/17014868/add-an-ipython-console-to-a-webpage > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -- Wes Turner https://westurner.github.io/ From doug.blank at gmail.com Sat Sep 27 19:05:08 2014 From: doug.blank at gmail.com (Doug Blank) Date: Sat, 27 Sep 2014 19:05:08 -0400 Subject: [IPython-dev] Highlighting code as program runs? In-Reply-To: References: Message-ID: Ok, so a few afternoon hacks later, and I have a prototype of a graphical stepper/debugger with code highlighting, graphical breakpoints, and slider control for speed. What do I mean? See example tracing Scheme factorial: https://www.youtube.com/watch?v=f8PvbMt6i1o I based my experiment on an animation example by Jake Vanderplas: http://jakevdp.github.io/blog/2013/05/19/a-javascript-viewer-for-matplotlib-animations/ I did a few experiments to play with CodeMirror and running code (fail): http://jupyter.cs.brynmawr.edu/hub/dblank/public/Experiments/Breakpoint%20Tests.ipynb Initially, I thought I'd use Widgets and real code execution. But ended up using raw Javascript and kernel.execute commands. There probably is a better way. In any event, the version in the video is just a prototype, but is designed to be code agnostic, working with any language through the MagicKernel's debug magic [1]. Not every language may be able to do this as easily as Scheme [2], however. -Doug [1] - https://github.com/blink1073/jupyter_kernel [2] - https://bitbucket.org/ipre/calico/src/master/src/calico_scheme_kernel/ and https://bitbucket.org/ipre/calico/src/master/src/calico/scheme.py On Tue, Sep 23, 2014 at 10:50 PM, Doug Blank wrote: > > We are currently running an external kernel (Scheme) based on the "wrapper kernel" [1]. We would like to have a mode such that we could highlight the expression in the code cell as the program "runs". > > Is there an example of something like this? If not, what would be the recommended method to do this? Perhaps a CodeWidget, with specialized comm message handling to highlight the text, with stepper controls? > > I see that CodeMirror supports highlighting an area [2]. Now, just need to be able to send the region bounds as the program runs, and receive them. > > Any pointers appreciated, > > -Doug > > [1] - http://ipython.org/ipython-doc/dev/development/wrapperkernels.html > > [2] - cell.code_mirror.markText({line: 6, ch: 2}, {line: 6, ch: 5}, {className: "styled-background"}); -------------- next part -------------- An HTML attachment was scrubbed... URL: From fperez.net at gmail.com Sat Sep 27 23:42:08 2014 From: fperez.net at gmail.com (Fernando Perez) Date: Sat, 27 Sep 2014 20:42:08 -0700 Subject: [IPython-dev] Highlighting code as program runs? In-Reply-To: References: Message-ID: On Sat, Sep 27, 2014 at 4:05 PM, Doug Blank wrote: > Ok, so a few afternoon hacks later, and I have a prototype of a graphical > stepper/debugger with code highlighting, graphical breakpoints, and slider > control for speed. What do I mean? See example tracing Scheme factorial: That's just awesome!! I do hope that something like this can become a robust/production tool. I so wish I had the time to work on it :) BTW, have you pinged Philip Guo about it? This is right up his alley, he might be interested... Cheers f -- Fernando Perez (@fperez_org; http://fperez.org) fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) fernando.perez-at-berkeley: contact me here for any direct mail -------------- next part -------------- An HTML attachment was scrubbed... URL: From ellisonbg at gmail.com Sat Sep 27 23:55:32 2014 From: ellisonbg at gmail.com (Brian Granger) Date: Sat, 27 Sep 2014 20:55:32 -0700 Subject: [IPython-dev] Highlighting code as program runs? In-Reply-To: References: Message-ID: Very awesome! I definitely think the widget route will be the way to go in the long run. Definitely get in touch with Philip Guo. Cheers, Brian On Sat, Sep 27, 2014 at 8:42 PM, Fernando Perez wrote: > On Sat, Sep 27, 2014 at 4:05 PM, Doug Blank wrote: >> >> Ok, so a few afternoon hacks later, and I have a prototype of a graphical >> stepper/debugger with code highlighting, graphical breakpoints, and slider >> control for speed. What do I mean? See example tracing Scheme factorial: > > > That's just awesome!! > > I do hope that something like this can become a robust/production tool. I so > wish I had the time to work on it :) > > BTW, have you pinged Philip Guo about it? This is right up his alley, he > might be interested... > > Cheers > > f > > -- > Fernando Perez (@fperez_org; http://fperez.org) > fperez.net-at-gmail: mailing lists only (I ignore this when swamped!) > fernando.perez-at-berkeley: contact me here for any direct mail > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -- Brian E. Granger Cal Poly State University, San Luis Obispo @ellisonbg on Twitter and GitHub bgranger at calpoly.edu and ellisonbg at gmail.com From stark at stat.berkeley.edu Sun Sep 28 23:15:49 2014 From: stark at stat.berkeley.edu (Philip B. Stark) Date: Sun, 28 Sep 2014 20:15:49 -0700 Subject: [IPython-dev] CSS styles / DOM elements for MathJax displayed equations in markdown cells Message-ID: First post: please forgive newbie ignorance, faux pas, etc.. Can someone tell me how MathJax displayed equations $$ ... $$ are classed when rendered as html in IPython Markdown cells, so I can override the relevant CSS? I'm trying to get more vertical padding above and below displayed equations. If somebody has a hack I can copy, that would be great. Thanks and best wishes, Philip -- Philip B. Stark | Professor and Chair | Department of Statistics | University of California Berkeley, CA 94720-3860 | 510-394-5077 | statistics.berkeley.edu/~stark | @philipbstark -------------- next part -------------- An HTML attachment was scrubbed... URL: From bussonniermatthias at gmail.com Mon Sep 29 02:36:27 2014 From: bussonniermatthias at gmail.com (Matthias Bussonnier) Date: Mon, 29 Sep 2014 08:36:27 +0200 Subject: [IPython-dev] CSS styles / DOM elements for MathJax displayed equations in markdown cells In-Reply-To: References: Message-ID: <53E179CB-ED6D-46E2-9C44-74CFE3D17934@gmail.com> Hi, First a warning, playing with mathjax can a can of worm, it is adjusted by mathjax people carefully to display correctly in many cases, and I don't think custom css is supported. That being said, the display equation are in a div with the following class : MathJax_Display I suggest you learn to play around with CSS/JS web inspector of your browser to experiment. For example: .MathJax_Display { padding: 30px; } Should work, cf screenshot, I don't think there is an easy way to target only markdown cell though. Cheers, -- M Le 29 sept. 2014 ? 05:15, Philip B. Stark a ?crit : > First post: please forgive newbie ignorance, faux pas, etc.. > > Can someone tell me how MathJax displayed equations $$ ... $$ are classed when rendered as html in IPython Markdown cells, so I can override the relevant CSS? I'm trying to get more vertical padding above and below displayed equations. If somebody has a hack I can copy, that would be great. > > Thanks and best wishes, > Philip > > -- > Philip B. Stark | Professor and Chair | Department of Statistics | University of California > Berkeley, CA 94720-3860 | 510-394-5077 | statistics.berkeley.edu/~stark | @philipbstark > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: Capture d??cran 2014-09-29 ? 08.33.56.png Type: image/png Size: 13316 bytes Desc: not available URL: From stark at stat.berkeley.edu Mon Sep 29 13:15:37 2014 From: stark at stat.berkeley.edu (Philip B. Stark) Date: Mon, 29 Sep 2014 10:15:37 -0700 Subject: [IPython-dev] CSS styles / DOM elements for MathJax displayed equations in markdown cells Message-ID: > > Thank you, Matthias! > That's exactly what I needed. Regards, Philip > ---------- Forwarded message ---------- > From: Matthias Bussonnier > To: IPython developers list > Cc: > Date: Mon, 29 Sep 2014 08:36:27 +0200 > Subject: Re: [IPython-dev] CSS styles / DOM elements for MathJax displayed > equations in markdown cells > Hi, > > > First a warning, playing with mathjax can a can of worm, it is adjusted by > mathjax people carefully to display correctly > in many cases, and I don't think custom css is supported. > > That being said, the display equation are in a div with the following > class : MathJax_Display > > I suggest you learn to play around with CSS/JS web inspector of your > browser to experiment. > For example: > > .MathJax_Display { > padding: 30px; > } > > Should work, cf screenshot, > I don't think there is an easy way to target only markdown cell though. > > Cheers, > -- > M > Le 29 sept. 2014 ? 05:15, Philip B. Stark a > ?crit : > > First post: please forgive newbie ignorance, faux pas, etc.. > > Can someone tell me how MathJax displayed equations $$ ... $$ are classed > when rendered as html in IPython Markdown cells, so I can override the > relevant CSS? I'm trying to get more vertical padding above and below > displayed equations. If somebody has a hack I can copy, that would be > great. > > Thanks and best wishes, > Philip > > -- > Philip B. Stark | Professor and Chair | Department of Statistics | > University of California > Berkeley, CA 94720-3860 | 510-394-5077 | statistics.berkeley.edu/~stark | > @philipbstark > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- Philip B. Stark | Professor and Chair | Department of Statistics | University of California Berkeley, CA 94720-3860 | 510-394-5077 | statistics.berkeley.edu/~stark | @philipbstark -------------- next part -------------- An HTML attachment was scrubbed... URL: -------------- next part -------------- A non-text attachment was scrubbed... Name: Capture d??cran 2014-09-29 ? 08.33.56.png Type: image/png Size: 13316 bytes Desc: not available URL: From lkb.teichmann at gmail.com Tue Sep 30 10:53:06 2014 From: lkb.teichmann at gmail.com (Martin Teichmann) Date: Tue, 30 Sep 2014 16:53:06 +0200 Subject: [IPython-dev] Asyncio extensions for IPython Message-ID: Hi, I've been working with the Python 3.4 asyncio package, which uses the yield from statement to perform asynchronous I/O. I realized that such an approach might also be useful for IPython, as it allows to start tasks in the background without stopping the currently running event loop, and without using threads. So I wrote an asyncio extension for IPython. It allows to use the yield from statement at the command line. The important difference to normal commands is, that while they are executed the currently running event loop continues, which is most visible if you are running something like matplotlib. So, while the I/O stuff is running "in the background", the matplotlib Qt window is still responsive. To give an example (don't forget you need python 3.4) In [1]: %load_ext yf # this is my extension In [2]: from asyncio import sleep, async In [3]: def f(): ...: yield from sleep(3) ...: print("done") ...: return "returned" In [4]: yield from f() #[wait three seconds] done Out[4]: 'returned' In [5]: async(f()) Out[5]: Task() In [6]: #[wait three seconds, or type other commands] done this is a trivial example which just sleeps, but the point is, it could do anything else, especially I/O, and still the GUI would be responsive. I put this extension onto github as https://github.com/tecki/ipython-yf Greetings Martin From lkb.teichmann at gmail.com Tue Sep 30 11:05:57 2014 From: lkb.teichmann at gmail.com (Martin Teichmann) Date: Tue, 30 Sep 2014 17:05:57 +0200 Subject: [IPython-dev] IPython inputhook, higher rate? In-Reply-To: References: Message-ID: Hi, I just saw this thread about why and how the python inputhook works, and how to integrate other event loops with IPython, using said input hooks. The actual problem is that the python input routine blocks while it reads from the console. This is completely unnecessary, as the underlying GNU readline library does not require a block at all. Down in the python interpreter, something like the following happens (it's in C in original). while True: PyOS_InputHook() select(stdin, timeout=100) if something_in_stdin: call_GNU_readline_to_read_one_char() so, python defines its own event loop! As one can see very clearly, from the IPython standpoint this is completely stupid: we want our own event loop to run (eg, the Qt event loop), and once something arrives at stdin, call GNU readline to process whatever arrived. I already wrote the necessary changes and already put up some patch on the python issue tracker: http://bugs.python.org/issue22412 Greetings Martin From takowl at gmail.com Tue Sep 30 13:06:49 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Tue, 30 Sep 2014 10:06:49 -0700 Subject: [IPython-dev] Asyncio extensions for IPython In-Reply-To: References: Message-ID: Hi Martin, Thanks, that's a fascinating extension. It's impressively little code to do something quite complex. I'm also glad to see someone making use of the ast_transformers hook. I noticed you've put it under a GPL license. Much of this ecosystem is BSD, so that means your code couldn't ever be integrated into a project like IPython. Of course the license is your choice, and I know people feel strongly about this, but if you would ever consider relicensing it, it's much easier to do that now than years down the line when you have to contact every contributor. Thanks, Thomas On 30 September 2014 07:53, Martin Teichmann wrote: > Hi, > > I've been working with the Python 3.4 asyncio package, which > uses the yield from statement to perform asynchronous I/O. > > I realized that such an approach might also be useful for IPython, > as it allows to start tasks in the background without stopping the > currently running event loop, and without using threads. So I wrote > an asyncio extension for IPython. It allows to use the yield from > statement at the command line. > > The important difference to normal commands is, that while they are > executed the currently running event loop continues, which is most > visible if you are running something like matplotlib. So, while the > I/O stuff is running "in the background", the matplotlib Qt window is > still responsive. > > To give an example (don't forget you need python 3.4) > > In [1]: %load_ext yf # this is my extension > In [2]: from asyncio import sleep, async > In [3]: def f(): > ...: yield from sleep(3) > ...: print("done") > ...: return "returned" > In [4]: yield from f() > #[wait three seconds] > done > Out[4]: 'returned' > In [5]: async(f()) > Out[5]: Task() > In [6]: #[wait three seconds, or type other commands] done > > this is a trivial example which just sleeps, but the point is, it could do > anything else, especially I/O, and still the GUI would be responsive. > > I put this extension onto github as > > https://github.com/tecki/ipython-yf > > Greetings > > Martin > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: From damianavila at gmail.com Tue Sep 30 13:16:54 2014 From: damianavila at gmail.com (=?UTF-8?Q?Dami=C3=A1n_Avila?=) Date: Tue, 30 Sep 2014 14:16:54 -0300 Subject: [IPython-dev] Asyncio extensions for IPython In-Reply-To: References: Message-ID: Wow... really nice... and I agree on Thomas suggestion. cheers. Damian 2014-09-30 14:06 GMT-03:00 Thomas Kluyver : > Hi Martin, > > Thanks, that's a fascinating extension. It's impressively little code to > do something quite complex. I'm also glad to see someone making use of the > ast_transformers hook. > > I noticed you've put it under a GPL license. Much of this ecosystem is > BSD, so that means your code couldn't ever be integrated into a project > like IPython. Of course the license is your choice, and I know people feel > strongly about this, but if you would ever consider relicensing it, it's > much easier to do that now than years down the line when you have to > contact every contributor. > > Thanks, > Thomas > > On 30 September 2014 07:53, Martin Teichmann > wrote: > >> Hi, >> >> I've been working with the Python 3.4 asyncio package, which >> uses the yield from statement to perform asynchronous I/O. >> >> I realized that such an approach might also be useful for IPython, >> as it allows to start tasks in the background without stopping the >> currently running event loop, and without using threads. So I wrote >> an asyncio extension for IPython. It allows to use the yield from >> statement at the command line. >> >> The important difference to normal commands is, that while they are >> executed the currently running event loop continues, which is most >> visible if you are running something like matplotlib. So, while the >> I/O stuff is running "in the background", the matplotlib Qt window is >> still responsive. >> >> To give an example (don't forget you need python 3.4) >> >> In [1]: %load_ext yf # this is my extension >> In [2]: from asyncio import sleep, async >> In [3]: def f(): >> ...: yield from sleep(3) >> ...: print("done") >> ...: return "returned" >> In [4]: yield from f() >> #[wait three seconds] >> done >> Out[4]: 'returned' >> In [5]: async(f()) >> Out[5]: Task() >> In [6]: #[wait three seconds, or type other commands] done >> >> this is a trivial example which just sleeps, but the point is, it could do >> anything else, especially I/O, and still the GUI would be responsive. >> >> I put this extension onto github as >> >> https://github.com/tecki/ipython-yf >> >> Greetings >> >> Martin >> _______________________________________________ >> IPython-dev mailing list >> IPython-dev at scipy.org >> http://mail.scipy.org/mailman/listinfo/ipython-dev >> > > > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > > -- *Dami?n* -------------- next part -------------- An HTML attachment was scrubbed... URL: From takowl at gmail.com Tue Sep 30 13:36:08 2014 From: takowl at gmail.com (Thomas Kluyver) Date: Tue, 30 Sep 2014 10:36:08 -0700 Subject: [IPython-dev] IPython inputhook, higher rate? In-Reply-To: References: Message-ID: Hi Martin, Thanks for looking into this. We would be interested in having a better way to integrate event loops with getting input in the terminal. It's probably not practical to push that straight into core Python, and even if it was, it would be some time before we could scrap our inputhook functionality in favour of a new feature in Python 3.5. You might want to look instead at basing it on a project like pyrepl, which implements readline-like features in Python. Its features list specifically mentions: "no hogging of control -- it should be easy to integrate pyrepl into YOUR application's event loop." Best wishes, Thomas On 30 September 2014 08:05, Martin Teichmann wrote: > Hi, > > I just saw this thread about why and how the python > inputhook works, and how to integrate other event loops > with IPython, using said input hooks. > > The actual problem is that the python input routine blocks > while it reads from the console. This is completely > unnecessary, as the underlying GNU readline library does > not require a block at all. Down in the python interpreter, > something like the following happens (it's in C in original). > > while True: > PyOS_InputHook() > select(stdin, timeout=100) > if something_in_stdin: > call_GNU_readline_to_read_one_char() > > so, python defines its own event loop! As one can see > very clearly, from the IPython standpoint this is completely > stupid: we want our own event loop to run (eg, the Qt > event loop), and once something arrives at stdin, call > GNU readline to process whatever arrived. > > I already wrote the necessary changes and already put > up some patch on the python issue tracker: > http://bugs.python.org/issue22412 > > Greetings > > Martin > _______________________________________________ > IPython-dev mailing list > IPython-dev at scipy.org > http://mail.scipy.org/mailman/listinfo/ipython-dev > -------------- next part -------------- An HTML attachment was scrubbed... URL: From zonca at sdsc.edu Tue Sep 30 18:23:10 2014 From: zonca at sdsc.edu (Andrea Zonca) Date: Tue, 30 Sep 2014 15:23:10 -0700 Subject: [IPython-dev] py.test plugin for running Notebook cells as unit tests Message-ID: Hi, I wrote a py.test plugin that discovers and runs unit tests written as cells of IPython notebooks, it also supports fixtures, see: https://github.com/zonca/pytest-ipynb http://zonca.github.io/2014/09/unit-tests-ipython-notebook.html Cheers, Andrea