matplotlib-cpp
matplotlib-cpp copied to clipboard
Unable/unclear to use keyword 'extent' with imshow
When setting the 'extent' keyword in the imshow function I receive the following error:
due to unexpected exception with message: Call to imshow() failed
How I call the imshow function:
PyObject* mat; plt::imshow(values, height, width, 1, {{"interpolation","bilinear"},{"origin", "lower"},{"aspect", "auto"}, {"extent","{0, 100, 0, 40}"}, &mat);
How could I provide imshow() with the extent keyword?
That's probably because "{0, 100, 0, 40}" is passed as string to matplotlib but it expects an array or list. That's another case of #184: currently it is only possible to pass string kwargs.
I suggested a solution for this in #241