Spaces:
Runtime error
Runtime error
File size: 218 Bytes
e619b9a | 1 2 3 4 5 6 7 8 9 10 11 | #src/preprocess.py
import cv2
import numpy as np
IMG_SIZE = 224
def preprocess_image(image):
image = cv2.resize(image, (IMG_SIZE, IMG_SIZE))
image = image / 255.0
return image.astype("float32")
|