imessam commited on
Commit
e167437
·
1 Parent(s): ff0add5

Delete transforms.py

Browse files
Files changed (1) hide show
  1. transforms.py +0 -32
transforms.py DELETED
@@ -1,32 +0,0 @@
1
- import tensorflow as tf
2
- import numpy as np
3
-
4
-
5
-
6
- def normalize(image,label):
7
-
8
- return tf.cast(image, tf.float32) / 255., label
9
-
10
-
11
- def resize(image,label):
12
-
13
- return tf.image.resize(image,size=(100,100)), label
14
-
15
-
16
- def flip(image,label):
17
-
18
- new_label = tf.random.uniform(shape=(), minval=0, maxval=2, dtype=tf.int32)
19
-
20
- img = image
21
-
22
- if new_label == 1:
23
- img = tf.image.flip_up_down(img)
24
-
25
- return img,new_label
26
-
27
-
28
-
29
-
30
-
31
-
32
-