Python Script - export images in table

Hi there,

I have a python script where some plots are created, which I need to pass to Knime. As I do not know in advance how many plots are created, I would like to store them in a table instead of using a static image port.

For testing purposes I tried to copy one image to the output dataframe / table:

...
output_image_1 = buffer.getvalue()
output_table_1 = pd.DataFrame(data={"ImageCol": output_image_1}, index=[0]).reset_index(drop=True)
...

It works, but then I get a column with a datatype of “Byte Vector”. How can I convert this column back into an image?