Пример #1
0
 def pdf(self, u: np.ndarray, log=False):
     sigma = self.sigma
     q = norm.ppf(u)
     d = mvn.logpdf(q, cov=sigma) - norm.logpdf(q).sum(1)
     return d if log else np.exp(d)
Пример #2
0
 def pdf(self, x: np.ndarray, log=False):
     sigma = self.sigma
     q = norm.ppf(x)
     d = mvn.logpdf(q, cov=sigma) - norm.logpdf(q).sum(1)
     return d if log else np.exp(d)
Пример #3
0
 def cdf(self, x: np.ndarray, log=False):
     q = norm.ppf(x)
     sigma = self.sigma
     return mvn.logcdf(q, cov=sigma) if log else mvn.cdf(q, cov=sigma)
Пример #4
0
 def cdf(self, x: np.ndarray, log=False):
     q = norm.ppf(x)
     sigma = self.sigma
     return mvn.logcdf(q, cov=sigma) if log else mvn.cdf(q, cov=sigma)