This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
@tf.custom_gradient | |
def binairy_STE_after_sigmoid(x): | |
def grad(dy): | |
return dy | |
result = tf.round(x) | |
return result, grad | |
def model(): |