Re:Tips and tricks to write LaTeX papers in with figures gen...
by stilley2 on Monday March 18, 2019 @06:46PM
(#19426121)
Thanks for the write-up! Two notes from my experience: pgf output works well with latex as well (although will slowdown compilation), and I recommend not using the pyplot submodule, especially if you'll be running things remotely over ssh and don't have a display
[ Parent
| on HN ]
Re:Tips and tricks to write LaTeX papers in with figures gen...
by alanbernstein on Monday March 18, 2019 @06:49PM
(#19426143)
Would you suggest an alternative to pyplot? What problems does it cause for you?
Re:Tips and tricks to write LaTeX papers in with figures gen...
by stilley2 on Monday March 18, 2019 @07:23PM
(#19426361)
I had problems using pyplot over ssh because it can assume there's a display and fail when it couldn't find one.
Maybe this has changed. I use the OO interface. For example https://matplotlib.org/gallery/api/agg_oo_sgskip.html
Re:Tips and tricks to write LaTeX papers in with figures gen...
by jpeloquin on Monday March 18, 2019 @07:53PM
(#19426568)
Changing the plot backend should fix this.
import matplotlib
matplotlib.use('Agg')
import matplotlib.pyplot as plt
https://stackoverflow.com/questions/2801882/generating-a-png...
Re:Tips and tricks to write LaTeX papers in with figures gen...
by stilley2 on Monday March 18, 2019 @11:08PM
(#19427746)
I believe Agg is only for bitmap output. While there are probably backends that work with a headless system, I find the OO option much more flexible.