tumor-prediction / utils.py
Skym616's picture
done
93f30c6
raw
history blame contribute delete
283 Bytes
import base64
import requests
def load_image(image_path):
with open(image_path, "rb") as img_file:
return base64.b64encode(img_file.read()).decode()
def load_lottie_url(url):
r = requests.get(url)
if r.status_code != 200:
return None
return r.json()