Skip to content

Commit

Permalink
fix: image save take 2
Browse files Browse the repository at this point in the history
  • Loading branch information
ispirtraian committed Apr 23, 2024
1 parent 91ef12e commit 0d9aa98
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions app/src/serving/serving_app.py
Original file line number Diff line number Diff line change
Expand Up @@ -344,8 +344,7 @@ def _predict_job (self, model_type: str, input, params:dict = None):
with open(task_content_path, 'wb') as file:
file.write(content.encode('utf-8'))
elif isinstance(content, Image.Image):
with content as img:
img.save(task_content_path, format=content.format)
content.save(task_content_path, format=content.format)
else:
raise Exception("Unsupported content type")

Expand Down

0 comments on commit 0d9aa98

Please sign in to comment.