码迷,mamicode.com
首页 > 其他好文 > 详细

pycharm远程ssh连接,配置在本地用matplotlib画图

时间:2018-06-22 22:44:59      阅读:558      评论:0      收藏:0      [点我收藏+]

标签:location   xxx   bsp   article   参考   系统   支持   怎么   details   

本地电脑是win10系统,用本地的pycharm,ssh连接到服务器。最近需用matplotlib画一些图,于是试着配置了一下。

主要需要配置x11 forwarding, Xming,

技术分享图片

配置ssh支持X11 farwarding

 

技术分享图片

开启Xming服务

 

技术分享图片

给pycharm配置DISPLAY变量,这一步不知道怎么没配好。

 

最终没实现用pycharm直接画图,只能勉强在的xshell上运行python代码之后,在本地桌面显示图像。虽然有点不方便,但总还是能用。

配置了半天,没配置好的时候,发现在xshell中输入xeyes,可以在本地桌面显示那一双眼睛,于是确定了本地电脑和服务器之间的X11 forwarding服务是调通了的。确定问题一定出在pycharm的配置上。

但是最终也没能在网上搜到是什么原因。

最后报的错误:

技术分享图片

最后的效果,在xshell中运行python xxx.py:

技术分享图片

 

 

参考:

https://blog.csdn.net/qq452727589/article/details/79011810

https://www.cnblogs.com/yinzm/p/8251118.html

http://www.yxtvg.com/toutiao/5408094/20171120A0HG3J00.html

https://blog.csdn.net/qq_22194315/article/details/77985441?fps=1&locationNum=9

https://blog.csdn.net/xiaopihaierletian/article/details/74999838

https://www.jianshu.com/p/a92e474dd657

pycharm远程ssh连接,配置在本地用matplotlib画图

标签:location   xxx   bsp   article   参考   系统   支持   怎么   details   

原文地址:https://www.cnblogs.com/HITSZ/p/9215559.html

(0)
(0)
   
举报
评论 一句话评论(0
登录后才能评论!
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!