I am trying to run a python script written in my local machine on a remote desktop using the following command line on terminal:
cat myscript.py | ssh username@machinename.departmentname.universityname.edu python
Python 3 under Anacanoda3 is installed on both local and remote machines. Here is the error message in the middle of the run while trying to display the plot:
QXcbConnection: Could not connect to display
What could be the reason and how to fix it? There were some other posts related to the same error message but for different reasons/usages.
You must use the -X parameter to activate window sharing.
cat myscript.py | ssh -X username@machinename.departmentname.universityname.edu python