这个应该和数据点没关系,我只是在5200(图的区间是0:10000)点这个点注释而已
画图我用的是pyplot
图形、注释可以正常画出来,就是savefig时报错,但换个点注释就没问题
报错信息:
PyError ($(Expr(:escape, :(ccall(#= C:\Users\vtchen.julia\packages\PyCall\0jMpb\src\pyfncall.jl:44 =# @pysym(:PyObject_Call), PyPtr, (PyPtr, PyPtr, PyPtr), o, pyargsptr, kw))))) <class ‘ValueError’>
ValueError(‘Given lines do not intersect. Please verify that the angles are not equal or differ by 180 degrees.’)
File “D:\Anaconda3\lib\site-packages\matplotlib\pyplot.py”, line 689, in savefig
res = fig.savefig(*args, **kwargs)
File “D:\Anaconda3\lib\site-packages\matplotlib\figure.py”, line 2094, in savefig
self.canvas.print_figure(fname, **kwargs)
File “D:\Anaconda3\lib\site-packages\matplotlib\backend_bases.py”, line 2075, in print_figure
**kwargs)
File “D:\Anaconda3\lib\site-packages\matplotlib\backends\backend_svg.py”, line 1218, in print_svg
result = self._print_svg(filename, fh, **kwargs)
File “D:\Anaconda3\lib\site-packages\matplotlib\backends\backend_svg.py”, line 1243, in _print_svg
self.figure.draw(renderer)
File “D:\Anaconda3\lib\site-packages\matplotlib\artist.py”, line 50, in draw_wrapper
return draw(artist, renderer, *args, **kwargs)
File “D:\Anaconda3\lib\site-packages\matplotlib\figure.py”, line 1649, in draw
renderer, self, artists, self.suppressComposite)
File “D:\Anaconda3\lib\site-packages\matplotlib\image.py”, line 138, in _draw_list_compositing_images
a.draw(renderer)
File “D:\Anaconda3\lib\site-packages\matplotlib\artist.py”, line 50, in draw_wrapper
return draw(artist, renderer, *args, **kwargs)
File “D:\Anaconda3\lib\site-packages\matplotlib\axes_base.py”, line 2610, in draw
mimage._draw_list_compositing_images(renderer, self, artists)
File “D:\Anaconda3\lib\site-packages\matplotlib\image.py”, line 138, in _draw_list_compositing_images
a.draw(renderer)
File “D:\Anaconda3\lib\site-packages\matplotlib\artist.py”, line 50, in draw_wrapper
return draw(artist, renderer, *args, **kwargs)
File “D:\Anaconda3\lib\site-packages\matplotlib\text.py”, line 2389, in draw
self.arrow_patch.draw(renderer)
File “D:\Anaconda3\lib\site-packages\matplotlib\patches.py”, line 4301, in draw
path, fillable = self.get_path_in_displaycoord()
File “D:\Anaconda3\lib\site-packages\matplotlib\patches.py”, line 4250, in get_path_in_displaycoord
self.get_mutation_aspect())
File “D:\Anaconda3\lib\site-packages\matplotlib\patches.py”, line 3210, in call
return self.transmute(path, mutation_size, linewidth)
File “D:\Anaconda3\lib\site-packages\matplotlib\patches.py”, line 3710, in transmute
tail_width / 2.)
File “D:\Anaconda3\lib\site-packages\matplotlib\bezier.py”, line 381, in get_parallels
cos_t2, sin_t2)
File “D:\Anaconda3\lib\site-packages\matplotlib\bezier.py”, line 35, in get_intersection
raise ValueError("Given lines do not intersect. Please verify that "
in top-level scope at base\none
in savefig at PyPlot\fZuOQ\src\PyPlot.jl:176
in #savefig#97 at PyPlot\fZuOQ\src\PyPlot.jl:179
in pycall at PyCall\0jMpb\src\pyfncall.jl:86
in #pycall#88 at PyCall\0jMpb\src\pyfncall.jl:11
in _pycall! at PyCall\0jMpb\src\pyfncall.jl:22
in __pycall! at PyCall\0jMpb\src\pyfncall.jl:44
in macro expansion at PyCall\0jMpb\src\exception.jl:84
in pyerr_check at PyCall\0jMpb\src\exception.jl:64
in pyerr_check at PyCall\0jMpb\src\exception.jl:60