griffithlab / pVACtools

http://www.pvactools.org
BSD 3-Clause Clear License
137 stars 59 forks source link

DISPLAY variable issue when running pvacvector visualize #1069

Closed Yonghao-Holden closed 6 months ago

Yonghao-Holden commented 6 months ago

Installation Type

Standalone

pVACtools Version / Docker Image

4.0.8

Python Version

Python 3.7.6

Operating System

Linux

Describe the bug

pvacvector run was done perfectly, and i got two output fasta files, Test_results.dna.fa and Test_results.fa However, when I try to run pvacvector visualize Test_results.fa ., it gave me this error: "Exception: DISPLAY environment variable not set. Unable to create vector visualization." I think issue #54 was discussing about this issue, but it's still confusing to me.

Thank you so much for your help!

How to reproduce this bug

pvacvector visualize Test_results.fa .

Input files

CMV_3,HHHD,Covid_1,HHHH,Covid_2,HHHC,CMV_1,HHHC,Flu_2,HHHC,Flu_3,HHHC,CMV_2,HHHC,Covid_4,HHHC,Covid_3,HHHC,Covid_5,HHHD,Covid_6,HHHD,Flu_1|Median_Junction_Score:4918.95909090909|Lowest_Junction_Score:506.24|All_Junction_Scores:856.85,2252.54,3863.26,14087.49,4059.83,1692.0,2112.74,23189.25,820.22,506.24,668.13 VLEETSVML HHHD LQPRTFLLK HHHH KQIYKTPPI HHHC VPMVATV HHHC MYSDFHF HHHC ILGFVFT HHHC VLAELVKQI HHHC VPMVATV HHHC RLITGRLQSL HHHC ALQIPFAMQM HHHD MLAKALRKV HHHD LGFVFTLTV

Log output

Traceback (most recent call last): File "/bar/yliang/anaconda3/bin/pvacvector", line 8, in sys.exit(main()) File "/bar/yliang/anaconda3/lib/python3.7/site-packages/pvactools/tools/pvacvector/main.py", line 50, in main args[0].func.main(args[1]) File "/bar/yliang/anaconda3/lib/python3.7/site-packages/pvactools/tools/pvacvector/visualize.py", line 35, in main raise Exception("DISPLAY environment variable not set. Unable to create vector visualization.") Exception: DISPLAY environment variable not set. Unable to create vector visualization.

Output files

No response

susannasiebert commented 6 months ago

I found this thread pretty helpful in understanding what the DISPLAY env variable is and why it might not be set:

If you are not using a graphical environment (i.e. you are logging in on the system console with no windows etc; or you are logging in remotely from a text-only terminal over SSH or similar, such as from a Windows computer running PuTTY) then no GUI is involved, and DISPLAY will typically be unset. Your only means of communicating with the computer is the command line (though there may be ways to pivot into a GUI session if you know how).

If you are logging in on the console with a graphical interface (on Ubuntu, typically the GDM greeter is used) or using a graphical terminal (such as from a Windows computer running eXceed or mobaX, or remote desktop software like a VNC client) the DISPLAY variable is set up by the program which manages your graphical session to indicate to graphical clients which I/O devices to connect to.

Traditionally, the GUI on an Ubuntu computer was running X.org, an X11 implementation

So, for one reason or another, DISPLAY not being set indicates that there is no GUI set up on the machine that is running the command. In the case described in #54 we were trying to run these commands on our compute cluster. The ssh -X solution mention in this ticket is setting up X-forwarding when logging into the cluster so that your local machine's GUI is used by the machine you are ssh'ing into. Hope this helps as a starting point to determine the solution for your particular compute setup.

Yonghao-Holden commented 6 months ago

Thank you so much for your quick response!

I'm running on a computing cluster with linux system. I tried ssh -X and set the DISPLAY variable as localhost:8888, but it still doesn't work. Do you have any suggestion what DISPLAY variable i should use?

Thank you again for your help!

Yonghao-Holden commented 6 months ago

I tested this instruction using X-11 forwarding (https://hpc.nmsu.edu/discovery/software/x11-forwarding/) and it worked. I have the figure generated, however, with very low resolution. Do you have any thoughts on how to increase the resolution? I will probably try to make the plot using the fasta file with ggplot instead.

vector

susannasiebert commented 6 months ago

Glad you were able to get it to work. I'm noticing the same thing on my end with the pixelation. It is sharp when it gets drawn but then blurry upon saving. I will investigate that issue.

Yonghao-Holden commented 6 months ago

Thank you for your timely help!