Update app.py
Browse files
app.py
CHANGED
|
@@ -12,7 +12,7 @@ LABELS = ['NORMAL', 'TUBERCULOSIS', 'PNEUMONIA', 'COVID19']
|
|
| 12 |
|
| 13 |
def predict_input_image(img):
|
| 14 |
try:
|
| 15 |
-
img = Image.open(BytesIO(base64.b64decode(img))).convert('RGB').resize((128,128))
|
| 16 |
img = np.array(img)
|
| 17 |
|
| 18 |
img_4d=img.reshape(-1,128,128,3)/img.max()
|
|
|
|
| 12 |
|
| 13 |
def predict_input_image(img):
|
| 14 |
try:
|
| 15 |
+
img = Image.open(BytesIO(base64.b64decode(img[22:]))).convert('RGB').resize((128,128))
|
| 16 |
img = np.array(img)
|
| 17 |
|
| 18 |
img_4d=img.reshape(-1,128,128,3)/img.max()
|