Spaces:
Build error
Build error
Update app.py
Browse files
app.py
CHANGED
@@ -10,7 +10,9 @@ with open("classlabel.txt", 'r') as file:
|
|
10 |
CLASS_LABEL = [x.strip() for x in file.readlines()]
|
11 |
|
12 |
def normalize_image(img):
|
13 |
-
img = tf.
|
|
|
|
|
14 |
img = tf.image.resize(img, (IMG_HEIGHT, IMG_WIDTH), method='bilinear')
|
15 |
return img
|
16 |
|
|
|
10 |
CLASS_LABEL = [x.strip() for x in file.readlines()]
|
11 |
|
12 |
def normalize_image(img):
|
13 |
+
img = tf.image.random_flip_left_right(img)
|
14 |
+
img = tf.image.random_rotation(img, 30)
|
15 |
+
img = tf.cast(img, tf.float32) / 255.0
|
16 |
img = tf.image.resize(img, (IMG_HEIGHT, IMG_WIDTH), method='bilinear')
|
17 |
return img
|
18 |
|