Downloading thousands of plots from a server sage notebook?
Hello! I made a few thousand 2D plots on an online sage notebook (legacy notebook, not jupyter). They are stored in a list. The computation took over a week and I'd like to avoid having to rerun.
What's the best way to download all of these plots as PNG files?
In the past, I have hacked it by looping over the list and .show()'ing the plots, downloading the notebook's HTML file, and cutting the plots from the directory (don't laugh). Usually showing a few hundred plots takes a while to show and I'm worried it may run out of memory and crash in this case.
Thanks in advance!
Edit: I should also mention I am not an admin on the server.
Suggestion : find in which directory your notebook files lives, and un-archive them (they are just compressed archives). You may see the pictures there.
Thanks for the reply. Unfortunately I am not an administrator on the server. Is there a way around this?
In what format do you have the plots? Is it something like
L = [plot(sin(x), (x, 0, 10)), plot(cos(x), (x, 0 10)), ...]
? If so, you could try thesave
orsave_image
methods for plots. Test withp = L[0]
and thenp.save(...)
orp.save_image(...)
.