'Theano backend use focal loss have some bug
My question is, how to rewrite the following two lines of code with theano 0.8.2 code:
from theano import tensor as T #(use T function rewrite code) pt_1 = tf.where(tf.equal(target, 1), output, tf.ones_like(output)) pt_0 = tf.where(tf.equal(target, 0), output, tf.zeros_like(output))
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|
