Some fix
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
Andrey Gumirov
2022-05-08 01:06:05 +07:00
parent efc711cd3b
commit aacb413176

View File

@ -16,7 +16,7 @@ def open_image_as_array(path):
def get_encoded_img(arr): def get_encoded_img(arr):
img = Image.fromarray(arr).convert("L") img = Image.fromarray(arr)
img_byte_arr = io.BytesIO() img_byte_arr = io.BytesIO()
img.save(img_byte_arr, format='PNG') img.save(img_byte_arr, format='PNG')
encoded_img = base64.encodebytes(img_byte_arr.getvalue()).decode('ascii') encoded_img = base64.encodebytes(img_byte_arr.getvalue()).decode('ascii')