9
比方說,你有一些代碼段像這樣張量流動懶惰?
import tensorflow as tf
...
f = h*y + z*t #Just some expression involving other tensors.
e = ... # some expression that does not involve f.
result = tf.select(b, e, f)
sess.run(result)
b是相同的形狀,E和F的布爾張量。 如果b的所有元素評估爲真,我們不需要 f並且結果將會是(或等於)e。
問題:當會話運行結果,和e的元素都是真實的,是評估?