From 4124ed575304f15d71811f09136344b2da60ea51 Mon Sep 17 00:00:00 2001 From: BrennerLittle <46569863+BrennerLittle@users.noreply.github.com> Date: Thu, 16 Jun 2022 12:50:26 -0700 Subject: [PATCH] Update activation.js Added Sigmoid --- netflow/js/core/activation.js | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/netflow/js/core/activation.js b/netflow/js/core/activation.js index 78ec1f0..6e1ef8e 100644 --- a/netflow/js/core/activation.js +++ b/netflow/js/core/activation.js @@ -11,4 +11,7 @@ function ReLu(x, def){ return Math.max(0, x); else return (x <= 0)?0:x; -} \ No newline at end of file +} +function Sigmoid(x){ + return 1 / (1 + Math.exp(-x)); +}