
Hi, all-- Has anyone seen this error, and do you have a way to get around it without re-launching yt? <error> plt.clf() File "/nics/b/home/collins/local_xt5/lib/python2.6/site-packages/matplotlib/pyplot.py", line 336, in clf gcf().clf() File "/nics/b/home/collins/local_xt5/lib/python2.6/site-packages/matplotlib/pyplot.py", line 273, in gcf return figure() File "/nics/b/home/collins/local_xt5/lib/python2.6/site-packages/matplotlib/pyplot.py", line 251, in figure **kwargs) File "/nics/b/home/collins/local_xt5/lib/python2.6/site-packages/matplotlib/backends/backend_tkagg.py", line 90, in new_figure_manager window = Tk.Tk() File "/nics/b/home/collins/local_xt5//lib/python2.6/lib-tk/Tkinter.py", line 1643, in __init__ self.tk = _tkinter.create(screenName, baseName, className, interactive, wantobjects, useTk, sync, use) _tkinter.TclError: no display name and no $DISPLAY environment variable </error> I'm running yt on kraken xt5 through a screen session that I have re-started after logging out and logging back in. This has not happened on other machines I've done this one. I tried setenv DISPLAY 666.666.6.6:0 (with the ip of the beast replaced with something real) but it didn't work. Thanks, d.

Hi Dave, So I think there are a couple things going on here. It looks like this is primarily a matplotlib problem. If you don't mind not having any interactive plotting, you should be able to set your ~/.matplotlib/matplotlibrc to have: backend: Agg This will prevent pyplot from spawning any X11-mediated widgets, and it might solve the problem you describe. If you start an interactive plotting session (which it looks like you might have) then disconnecting and reconnecting your screen will cause it to think that it still has access to the underlying toolkit and widgets it has already instantiated. The X11 authentication system, I believe, is resistant to such things -- so even if you were able to tell matplotlib/pyplot "Hey, my widgets are dead -- can you please reconstruct them all?" the X11 auth system would argue that it no longer has privileges to address your screen. This may be incorrect, but from my own experience this has been the case. The second possible approach would be to change the pyplot rendering engine on the fly. I don't believe this is possible -- but if you could start with tkAgg, reconnect somewhere else and switch to Agg, then you could save to disk and view through an image viewer like xv or gqview (my favorite.) If this is possible, your best bet would be to ask on matplotlib-users. (and then let us know :) But -- if you're just doing yt-based plots (which you're not here, from what I can tell) I am pretty sure you can fool yt into changing rendering engines within a single instantiation of the python interpreter. The FigureCanvas is stored in the "engineVals" dictionary, and changing that would change the output format. However, all of that aside -- I don't know if Kraken allows VNC sessions (I'm inclined to suspect they do not.) If they do, you can set one up and ssh tunnel to it. Because they do round-robin login nodes, this probably won't work. You might be able to set one up and then X11 forward a client running remotely, however, which could get you what you want. In short: I believe disconnectin/reconnecting with X11 widgets is a hard problem -- if somebody else knows better, though, I'd be very grateful to hear. I tend to do my viz either mediated by ~/public_html/ or through VNC. -Matt On Tue, Mar 31, 2009 at 11:13 PM, david collins <antpuncher@gmail.com> wrote:
Hi, all--
Has anyone seen this error, and do you have a way to get around it without re-launching yt?
<error> plt.clf() File "/nics/b/home/collins/local_xt5/lib/python2.6/site-packages/matplotlib/pyplot.py", line 336, in clf gcf().clf() File "/nics/b/home/collins/local_xt5/lib/python2.6/site-packages/matplotlib/pyplot.py", line 273, in gcf return figure() File "/nics/b/home/collins/local_xt5/lib/python2.6/site-packages/matplotlib/pyplot.py", line 251, in figure **kwargs) File "/nics/b/home/collins/local_xt5/lib/python2.6/site-packages/matplotlib/backends/backend_tkagg.py", line 90, in new_figure_manager window = Tk.Tk() File "/nics/b/home/collins/local_xt5//lib/python2.6/lib-tk/Tkinter.py", line 1643, in __init__ self.tk = _tkinter.create(screenName, baseName, className, interactive, wantobjects, useTk, sync, use) _tkinter.TclError: no display name and no $DISPLAY environment variable </error>
I'm running yt on kraken xt5 through a screen session that I have re-started after logging out and logging back in. This has not happened on other machines I've done this one. I tried setenv DISPLAY 666.666.6.6:0 (with the ip of the beast replaced with something real) but it didn't work.
Thanks, d. _______________________________________________ yt-users mailing list yt-users@lists.spacepope.org http://lists.spacepope.org/listinfo.cgi/yt-users-spacepope.org

Hi Dave,
However, all of that aside -- I don't know if Kraken allows VNC sessions (I'm inclined to suspect they do not.) If they do, you can set one up and ssh tunnel to it. Because they do round-robin login nodes, this probably won't work. You might be able to set one up and While it's true that kraken.tvshow.deepsouth.edu is indeed a round-robin you can log directly into any of the head nodes directly. In fact, on the website they even specifically suggest this for large file transfer. I would try that. I don't know if they VNC, though, and kraken is down at the moment.
j
participants (3)
-
david collins
-
j s oishi
-
Matthew Turk