Skip to content

Commit e7fce38

Browse files
authored
Update filter_ops.py (#1657)
currently for every mode value other than None - a 'NameError: name 'upper' is not defined' was thrown due to misuse of the 'upper' method
1 parent 962dd70 commit e7fce38

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

tensorflow_io/python/experimental/filter_ops.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@
2222
def pad(input, ksize, mode, constant_values):
2323
input = tf.convert_to_tensor(input)
2424
ksize = tf.convert_to_tensor(ksize)
25-
mode = "CONSTANT" if mode is None else upper(mode)
25+
mode = "CONSTANT" if mode is None else str.upper(mode)
2626
constant_values = (
2727
tf.zeros([], dtype=input.dtype)
2828
if constant_values is None

0 commit comments

Comments
 (0)