I noticed that when XLA is used for inference for a tf.function, grappler is not being executed. is this the expected behavior? why is that?
import tensorflow as tf
a = tf.reshape(tf.range(1, 28, dtype=float),[3,3,3])
b = tf.reshape(tf.range(10, -17, -1, dtype=float),[3,3,3])
--> either @tf.function(jit_compile=True) or @tf.function
def myfunc(a, b):
c = a + b
d = c * b
e = d / a
return e
print(myfunc(a, b))
this script executes with grappler when only using @tf.function but when adding jit_compile=True, grappler is not running.