pycharm报错 Error: failed to send plot to http://127.0.0.1:63342及Connection Refused Error: [Errno 111]

Article content source

The content of the article comes from the link above, and I summarize it here for my convenience in the future

pycharm报错 Error: failed to send plot to http://127.0.0.1:63342及Connection Refused Error: [Errno 111]

When pycharm runs a drawing.py, an error occurs. It's still good before eating, but it's G after eating

In fact, 这个demoit has finished running, and the data can be displayed, but an error is reported when displaying the picture, that is, there is a problem with the connection when the picture is sent back from the server to pycharm .

The code I run on the remote server should occupy the port http://127.0.0.1:63342.

Summary of solutions:

  1. Directly cancel the picture display, settings > tools > Python Scientific uncheck Show plots in tool window (but I just want it to be displayed, this is only applicable to those who can not view the picture. I also tried this method, very nice , But I need diagrams )
  2. Set up a firewall (basically not because of this one)
  3. Turn down the dpi setting (probably the image is too large to display)
  4. Turn off Set Canvas Size
  5. Run pycharm as an administrator ( I use this method, it's outrageous )
  6. Close the accumulated images in the drawing window, (there are too many images to display new ones)
  7. To establish a remote port and a local channel, enter the command in cmd: ssh -R 63342:127.0.0.1:63342 user@serverIP(this is temporarily not available)
  8. Turn off the proxy, search for Network and Sharing Center→Internet Properties→Local Area Network (LAN) Settings in the settings, and uncheck the automatic detection and proxy server. (This one is very possible, I saw a lot of people because of this one)

Another way is to save the output picture, and then use the os module to automatically open the picture for viewing.

Guess you like

Origin blog.csdn.net/qq_43585922/article/details/129717582