Spaces:
Running
Running
Update script.js
Browse files
script.js
CHANGED
@@ -23,7 +23,7 @@ var rand_truncated_normal = function(low, high) {
|
|
23 |
|
24 |
var softplus = function(x) {
|
25 |
const m = tf.maximum(x, 0.0);
|
26 |
-
return tf.add(m, tf.log(tf.add(tf.exp(
|
27 |
}
|
28 |
|
29 |
|
|
|
23 |
|
24 |
var softplus = function(x) {
|
25 |
const m = tf.maximum(x, 0.0);
|
26 |
+
return tf.add(m, tf.log(tf.add(tf.exp(tf.neg(m)), tf.exp(tf.sub(x, m)))));
|
27 |
}
|
28 |
|
29 |
|