MCPcopy Create free account
hub / github.com/MrNothing/AI-Blocks / xavier_init

Function xavier_init

Sources/scripts/neural_network.py:36–39  ·  view source on GitHub ↗
(self, size)

Source from the content-addressed store, hash-verified

34 self.variables.append(b)
35
36def xavier_init(self, size):
37 in_dim = size[0]
38 xavier_stddev = 1. / tf.sqrt(in_dim / 2.)
39 return tf.random_normal(shape=size, stddev=xavier_stddev)
40
41def Run(self, h, reuse=False):
42 Log("Running "+self.name)

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected