What I have when I convert an png image into blocks then add the section sign (§), I then convert it to a string using:
lframe = [e.encode('utf-8') for e in frame.split(',')]
but when I do, it gives me a:
['\xc2\xa70\xe2\x96\x88\xe2\x96\x88\xe2\x96\x88\xe2\x96\x88\xe2\x96\x88\xe2\x96\
x88\xe2\x96\x88\xc2\xa76\xe2\x96\x88\xe2\x96\x88\xc2\xa70\xe2\x96\x88\xe2\x96\x8
8\xe2\x96\x88\xe2\x96\x88\xe2\x96\x88\xe2\x96\x88\xe2\x96\x88\xc2\xa7r']
What I want to do, is to find a way to convert my output into something like
['\xc2','\xa70','\xe2','\x96','\x88'...]
Thanks!
The code below should do what you want.
lframe = [x for x in [e.encode('utf-8') for e in frame.split(',')][0]]