On 9/4/19 8:10 PM, Alan W. Irwin wrote:
On 2019-09-04 21:32+0200 Xavier Cardil wrote:

Hi, we are using Plplot on a project with Keras, where we are required to
feed plots as RGBA encoded string plot. Is it possible to do this somehow ?

I have read about plsmema( )

http://plplot.sourceforge.net/docbook-manual/plplot-html-5.15.0/plsmema.html

But this looks to be a way to input, not to output ?

Hi Xavier:

Yes, plsmema is input so I don't think it is suitable for your described needs.

Sorry it isn't clear to me what is meant by input here, so I will plow ahead. The function plsmema sets the memory space for the memcairo to use when plotting. So it is input in the sense that you pass it a pointer to the memory where you want the plot rendered. But it is also output in the sense that the memcairo drive will fill this memory with the plot image. If you then saved this block of memory as an (RGBA) image you would see the plot. If you are looking to pass pictures of plots to Keras then might be what you are looking for.

Though not a "official example", there is a Python example that uses this function:

plplot/examples/python/test_plsmem.py.in

-Hazen


_______________________________________________
Plplot-general mailing list
Plplot-general@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/plplot-general

Reply via email to