matploltib use gpu ?

> My problem: I have about 10 million point to plot.
>
> with this example, moving in the graph is very slow.
> Is there a way to have an intelligent zoom which removes invisible items
on
> the eye?
>
>
>
> import matplotlib
> matplotlib.use('TkAgg')
> import numpy
> from numpy import arange, sin, pi
> from matplotlib.backends.backend_tkagg import FigureCanvasTkAgg,
> NavigationToolbar2TkAgg
> from matplotlib.figure import Figure
> import tkinter as Tk
>
> root = Tk.Tk()
> root.wm_title("Embedding in TK")
>
>
> f = Figure(figsize=(5, 4), dpi=100)
> a = f.add_subplot(111)
>
>
> t = arange(0.0, 10000000, 1)
> s = arange(0.0, 10000000, 1)
> a.plot(t, s)
>
>
> canvas = FigureCanvasTkAgg(f, master=root)
> canvas.show()
> canvas.get_tk_widget().pack(side=Tk.TOP, fill=Tk.BOTH, expand=1)
>
> toolbar = NavigationToolbar2TkAgg(canvas, root)
> toolbar.update()
> canvas._tkcanvas.pack(side=Tk.TOP, fill=Tk.BOTH, expand=1)
>
>
> def _quit():
> root.quit()
> root.destroy()
>
> button = Tk.Button(master=root, text='Exit', command=_quit)
> button.pack(side=Tk.BOTTOM)
>
> Tk.mainloop()

Afternoon,

Have you considered enabling Rasterization?
a.plot(t, s, rasterized=True)
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.python.org/pipermail/matplotlib-users/attachments/20160129/1e1d9036/attachment.html&gt;

ยทยทยท

On Mon, Jan 25, 2016 at 12:35 PM, nice <sazearte at live.fr> wrote: