-- BEGIN things stolen from https://crypto.stanford.edu/~blynn/haskell/brain.html

gauss :: Float -> IO Float
gauss stdev = do
  x1 <- randomIO
  x2 <- randomIO
  return $ stdev * sqrt (-2 * log x1) * cos (2 * pi * x2)

-- f is activation function
-- ws is weights
-- b is bias
-- as is inputs
gauss :: Float -> IO Float
gauss stdev = do
  x1 <- randomIO
  x2 <- randomIO
  return $ stdev * sqrt (-2 * log x1) * cos (2 * pi * x2)

-- f is activation function
-- ws is weights
-- b is bias
-- as is inputs
gauss stdev = do
  x1 <- randomIO
  x2 <- randomIO
  return $ stdev * sqrt (-2 * log x1) * cos (2 * pi * x2)

-- f is activation function
-- ws is weights
-- b is bias
-- as is inputs