MCPcopy Create free account
hub / github.com/Anoise/WTFlib / encode

Method encode

LDPS_Graph/layers/utils.py:305–307  ·  view source on GitHub ↗
(self, x)

Source from the content-addressed store, hash-verified

303 self.eps = eps
304
305 def encode(self, x):
306 x = (x - self.mean) / (self.std + self.eps)
307 return x
308
309 def decode(self, x, sample_idx=None):
310 x = (x * (self.std + self.eps)) + self.mean

Callers

nothing calls this directly

Calls

no outgoing calls

Tested by

no test coverage detected