How to covert image data to string

Discussion related to "under the hood" OpenMV topics.
skylin008
Posts: 65
Joined: Mon Mar 13, 2017 10:18 pm

How to covert image data to string

Postby skylin008 » Sun Mar 15, 2020 6:14 am

hello, every one! How to convert the Image data to string or list data .Thanks !
User avatar
kwagyeman
Posts: 4436
Joined: Sun May 24, 2015 2:10 pm

Re: How to covert image data to string

Postby kwagyeman » Sun Mar 15, 2020 12:35 pm

compress() on the image. It's then a jpg byte string. If you want the image in a string with an rgb value per byte you can manually write python code to access each pixel and spit out text.
Nyamekye,

Return to “Technical Discussion”

Who is online

Users browsing this forum: Baidu [Spider] and 4 guests