<br><br><div class="gmail_quote">On Fri, Sep 16, 2011 at 15:50, Jason Grout <span dir="ltr"><<a href="mailto:jason-sage@creativetrax.com">jason-sage@creativetrax.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">

<div class="im">On 9/16/11 3:37 PM, Chris Kees wrote:<br>
> Hi,<br>
><br>
> I updated my source on the notebook after I read Fernando's post. Nice<br>
> work! Couple of questions:<br>
><br>
> Is there a way to use reST in the text boxes? It seems like it sort of<br>
> works but doesn't get the ::<br>
><br>
> If I put the notebook safely inside our firewall, would it be<br>
> reasonable to just let 5-10 people use the same server or do you<br>
> foresee problems down the road? I've set up a sage server partly for<br>
> that purpose, but having the ipython notebook available could have<br>
> some advantages. For example, we're running a computational mechanics<br>
> seminar where it would be nice to share some simple mpi programs, say<br>
> in the 8-16 processor range. I don't think we can do that in sage yet,<br>
> right?<br>
<br>
</div>(answering the Sage question here...) What do you mean when you say<br>
"share some simple mpi programs"?  Do you mean running the mpi programs<br>
from the command line, or sharing the C code files, or using mpi4py to<br>
run the programs?  If you can do it in python or on the command line,<br>
you can likely do it in Sage.  Feel free to email the sage-support list;<br>
I'm sure we can help you there.<br>
<div class="im"><br>
<br>
<br>
><br>
> In the docs, it talks about the python roundtrip not being guaranteed.<br>
> What about a sage round trip capability for the notebooks?<br>
<br>
</div>I think that might be possible, though it would require ipython being<br>
able to have "text cells" with arbitrary html, rather than just<br>
markdown.  The Sage notebook format looks something like:<br></blockquote><div><br></div><div>since (almost) arbitrary html is valid markdown, I don't expect a problem there.  The first notebook draft had html text cells, but we never found any HTML we wanted to use that didn't work as-is in markdown, so we disabled it to prevent unnecessary clutter.  If there are real HTML use cases for which the markdown transforms html inappropriately, we can easily turn it back on.</div>

<div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<br>
arbitrary html<br>
<br>
{{{<br>
input<br>
///<br>
output<br>
}}}<br>
<br>
arbitrary html<br>
<br>
{{{<br>
input<br>
///<br>
output<br>
}}}<br>
<br>
arbitrary html<br>
<br>
etc.<br></blockquote><div><br></div><div>That seems simple enough, though after playing with a few sage worksheets, it looks like if you make an HTML cell, it is indistinguishable from a code cell in the exported file.  Presumably, IPython would only want the Python/Sage cells as code cells, whereas all the latex, text, and html cells should come out as text.  If Sage doesn't distinguish between these in the file-format, then I'm not sure what we should do.  Detecting the language based purely on content will certainly not be acceptable.</div>

<div><br></div><div>But the fact that Sage can have HTML that is part of a cell, as well as HTML that is *not* part of a cell makes it clear that a roundtrip will not result in an identical notebook.  It may have the same content, but it will have changed structure at least partly.  This is what we mean when we talk about lacking roundtrip support - not that you can't import to/export from a format, but that doing so is not guaranteed to preserve the entire document structure.</div>

<div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">
<br>
Of course, sage-specific things like interacts wouldn't work.  (However,<br>
over the summer we've written a version of interacts that is independent<br>
of Sage and relies instead on the new ipython messaging protocol; it's<br>
part of the single-cell server project:<br>
<a href="http://utmost.aimath.org/#august-2011" target="_blank">http://utmost.aimath.org/#august-2011</a>.)<br></blockquote><div><br></div><div>Very cool!</div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">


<br>
Thanks,<br>
<br>
Jason<br>
<font color="#888888"><br>
--<br>
Jason Grout<br>
</font><div><div></div><div class="h5">_______________________________________________<br>
IPython-dev mailing list<br>
<a href="mailto:IPython-dev@scipy.org">IPython-dev@scipy.org</a><br>
<a href="http://mail.scipy.org/mailman/listinfo/ipython-dev" target="_blank">http://mail.scipy.org/mailman/listinfo/ipython-dev</a><br>
</div></div></blockquote></div><br>