mirror of
https://github.com/SheffieldML/GPy.git
synced 2026-05-02 08:12:39 +02:00
[normalize]
This commit is contained in:
parent
7ec0e75c0e
commit
a3c8739f9e
2 changed files with 8 additions and 5 deletions
|
|
@ -37,6 +37,7 @@ class GaussianNorm(Norm):
|
|||
Y = np.ma.masked_invalid(Y, copy=False)
|
||||
self.mean = Y.mean(0).view(np.ndarray)
|
||||
self.std = Y.std(0).view(np.ndarray)
|
||||
self.std[self.std==0] = 1.
|
||||
def normalize(self, Y):
|
||||
return ((Y-self.mean)/self.std)
|
||||
def inverse_mean(self, X):
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue