Skip to content

Headless plotting? #1

@sfeister

Description

@sfeister

Headless plotting is not implemented; currently requires X11 forwarding if running on a server.

Traceback

 (most recent call last):
  File "prorad.py", line 734, in <module>
    main()
  File "prorad.py", line 78, in main
    plot_results(grid, film_x, film_y, Ep, traces, plot_fluence=True, plot_traces=True, plot_quiver=False, save_images=True)
  File "prorad.py", line 665, in plot_results
    fig = plt.figure(2,figsize=(8,8))
  File "/software/python-2.7.12-el7-x86_64/lib/python2.7/site-packages/matplotlib/pyplot.py", line 535, in figure
    **kwargs)
  File "/software/python-2.7.12-el7-x86_64/lib/python2.7/site-packages/matplotlib/backends/backend_tkagg.py", line 81, in new_figure_manager
    return new_figure_manager_given_figure(num, figure)
  File "/software/python-2.7.12-el7-x86_64/lib/python2.7/site-packages/matplotlib/backends/backend_tkagg.py", line 89, in new_figure_manager_given_figure
    window = Tk.Tk()
  File "/software/python-2.7.12-el7-x86_64/lib/python2.7/lib-tk/Tkinter.py", line 1815, in __init__
    self.tk = _tkinter.create(screenName, baseName, className, interactive, wantobjects, useTk, sync, use)
_tkinter.TclError: couldn't connect to display "localhost:16.0"

This could be corrected using the matplotlib 'Agg' plotter, which would also suppress GUI popups. I'll see about pushing a change.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions