export_png正在超时

时间:2019-03-26 14:31:16

标签: python bokeh

我试图将bokeh图形另存为png文件,但是每当我使用export_png时,它都会返回此错误:

    File "/home/tuf60598/anaconda3/lib/python3.6/site-packages/urllib3/connectionpool.py", line 601, in urlopen
chunked=chunked)
    File "/home/tuf60598/anaconda3/lib/python3.6/site-packages/urllib3/connectionpool.py", line 387, in _make_request
six.raise_from(e, None)
    File "<string>", line 2, in raise_from
    File "/home/tuf60598/anaconda3/lib/python3.6/site-packages/urllib3/connectionpool.py", line 383, in _make_request
httplib_response = conn.getresponse()
    File "/home/tuf60598/anaconda3/lib/python3.6/http/client.py", line 1331, in getresponse
response.begin()
    File "/home/tuf60598/anaconda3/lib/python3.6/http/client.py", line 297, in begin
version, status, reason = self._read_status()
    File "/home/tuf60598/anaconda3/lib/python3.6/http/client.py", line 266, in _read_status
raise RemoteDisconnected("Remote end closed connection without"
    urllib3.exceptions.ProtocolError: ('Connection aborted.', RemoteDisconnected('Remote end closed connection without response',))

这就是我所说的:

    p = figure(plot_width=1000, plot_height=1000, x_axis_label='time(in seconds)',y_axis_label='y', title="Accesses over time")`

    p.circle(x, y, size=4, color="navy", alpha=0.5)

    export_png(p, filename="access_over_time.png")

为什么会这样?

注意:仅当我尝试绘制具有数百万行的数据集时,才会发生这种情况。否则,在处理具有约3万行的数据集时,不会出现任何错误。

0 个答案:

没有答案