edit: 안광학 서버 입고 세팅
This commit is contained in:
@@ -65,8 +65,10 @@ def save_base64_as_image_file(base64_data: str, output_path: str):
|
||||
"""
|
||||
Base64 문자열을 디코딩하여 이미지 파일로 저장합니다.
|
||||
"""
|
||||
# Base64 문자열을 디코딩하여 이진 데이터로 변환합니다.
|
||||
decoded_data = base64.b64decode(base64_data)
|
||||
with open(output_path, "wb") as image_file:
|
||||
image_file.write(decoded_data)
|
||||
|
||||
try:
|
||||
# Base64 문자열을 디코딩하여 이진 데이터로 변환합니다.
|
||||
decoded_data = base64.b64decode(base64_data)
|
||||
with open(output_path, "wb") as image_file:
|
||||
image_file.write(decoded_data)
|
||||
except Exception as e:
|
||||
raise Exception(f"input image data error : {e}")
|
||||
Reference in New Issue
Block a user