Matplotlib plot with TkAgg and cuda

I saw in this github issue [Bug]: GPU memory leak with plt.figure() · Issue #22448 · matplotlib/matplotlib · GitHub that matplotlib tkagg plt can be displayed on Nvidia. I need to know how configuring matplotlib or which environment variables should i add to get matplotlib with GPU.