Zhibinhong commited on
Commit
8941627
1 Parent(s): baaad9e

Update handler.py

Browse files
Files changed (1) hide show
  1. handler.py +1 -1
handler.py CHANGED
@@ -20,5 +20,5 @@ class EndpointHandler():
20
  img = self.pipe(text).images[0]
21
  img.save("./1.png")
22
  with open('./1.png','rb') as img_file:
23
- encoded_string = base64.b64encode(image_file.read())
24
  return {'image':encoded_string}
 
20
  img = self.pipe(text).images[0]
21
  img.save("./1.png")
22
  with open('./1.png','rb') as img_file:
23
+ encoded_string = base64.b64encode(img_file.read())
24
  return {'image':encoded_string}