[IPython-dev] notebook questions
Fri Sep 16 22:41:23 CDT 2011
On Fri, Sep 16, 2011 at 20:08, Chris Kees <email@example.com> wrote:
> On Fri, Sep 16, 2011 at 4:14 PM, MinRK <firstname.lastname@example.org> wrote:
> > On Fri, Sep 16, 2011 at 13:37, Chris Kees <email@example.com> wrote:
> >> Hi,
> >> I updated my source on the notebook after I read Fernando's post. Nice
> >> work! Couple of questions:
> >> Is there a way to use reST in the text boxes? It seems like it sort of
> >> works but doesn't get the ::
> > No, it uses markdown, which is largely similar, if simpler, and much
> > suited for
> > use in a browser. Indent code blocks by four spaces, and it should
> > behave nicely. Or use `<pre>` tags if you just want it monospaced and
> > highlighted.
> I noticed that github allows you to choose between several different
> languages for wiki input so I thought you might have something like
> that in mind. I've been using reST for docstrings, sphinx docs, and
> github so I selfishly would prefer not to have to learn another
> simplified markup language.
That makes sense, and I expect we will get this request often. The problem
is reST is really a horrible language
for in-browser cell markup (as opposed to full document markup, for which it
is designed), and for many simple cases
writing as if it were reST will result in the same output in markdown.
> >> If I put the notebook safely inside our firewall, would it be
> >> reasonable to just let 5-10 people use the same server or do you
> >> foresee problems down the road?
> > This should be fine, as long as it is acceptable for the 5-10 people to
> > running code as the user that launched the server. Anyone with access to
> > the server can run arbitrary code on the host as this user. If this is
> > acceptable, there should be no problem. One thing to be careful of is
> > simultaneously working with a single notebook: You can both be working
> > the same file, but saving is destructive. So if two people open a
> > both edit it, and both save it, the later save will clobber the first.
> I could set up a special user or virtual machine like is done for sage
> servers, and then we could just use a convention that your always save
> worksheets in notebooks ending in your initials. One flaw in that plan
> is that the current notebook doesn't appear to have a "duplicate" or
> "save as" capability, but I'm guessing that would be very easy to add.
> I like the integrated version control idea that Anne Archibald
> mentioned in her blog.
Yes, integrated version control is one of the very first features we got
long before a single line of code was written, and will hopefully support
> >> I've set up a sage server partly for
> >> that purpose, but having the ipython notebook available could have
> >> some advantages. For example, we're running a computational mechanics
> >> seminar where it would be nice to share some simple mpi programs, say
> >> in the 8-16 processor range. I don't think we can do that in sage yet,
> >> right?
> >> In the docs, it talks about the python roundtrip not being guaranteed.
> >> What about a sage round trip capability for the notebooks?
> > I don't know about the Sage notebook's file formats, but it is unlikely.
> > That doesn't mean that it won't work at all, or even well, but lossless
> > roundtrip is generally not feasible between file formats with different
> > capabilities.
> I understand about the perfect lossless roundtrip being impossible in
> general. I'd be happy with a convert script that goes back and forth
> with warnings or comments (sort of like a failed merge). As long as
> the python part works and most of the text makes it on the round trip
> it seems valuable to me. One can invest quite a bit of effort into
> these notebooks, and I like the idea of being able to convert them to
> high quality python code or sage with minimal effort.
Yes, one (or few) time export or import should not be a problem. Just
don't expect to be able to reliably be going back and forth between
environments with continued edits, which clean roundtrip would get you.
> >> What's the latest recommendation for interactive 3D graphics in the
> >> notebook, or what direction should I investigate? Probably the most
> >> straightforward route for me would be to take our existing vtk
> >> representations that we use with Qt and follow the notebook example on
> >> the display protocol. Also, BTW, is there a PySide qt gui example
> >> somewhere?
> > The IPython notebook currently has no mechanism for interactive graphics.
> > All the usual interactive tools should work if you are running the
> > server *locally*, as their windows will pop up as usual. You can publish
> > static HTML, SVG, PNG, or txt representations of objects, but not dynamic
> > (unless you write the dynamic part into the HTML/JS output).
> OK, that gives a path forward. Most of our graphics is done in vtk so
> I asked the paraview list whether the JS support from the ParaViewWeb
> project is available from python yet
> >> Thanks,
> >> Chris
> >> _______________________________________________
> >> IPython-dev mailing list
> >> IPythonfirstname.lastname@example.org
> >> http://mail.scipy.org/mailman/listinfo/ipython-dev
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the IPython-dev