4e70cb5fc9a9494e866ccd7d2e1a9046091b6337,astroML/density_estimation/gauss_mixture.py,GaussianMixture1D,__init__,#GaussianMixture1D#Any#Any#Any#,18
Before Change
weight of component distributions (default = 1)
def __init__(self, means=0, sigmas=1, weights=1):
data = np.array([t for t in np.broadcast(means, sigmas, weights)])
precisions = [1/s**2 for s in sigmas]
self._gmm = GaussianMixture(data .shape[0],
weights_init=data[:, 2] / data[:, 2].sum(),
means_init=data[:, :1],
covariance_type="spherical",
After Change
weight of component distributions (default = 1)
def __init__(self, means=0, sigmas=1, weights=1):
components = len(means)
self._gmm = GaussianMixture(components, covariance_type="spherical")
self._gmm.weights_ = weights / weights.sum()
self._gmm.means_ = means.reshape(-1, 1)
self._gmm.covariances_ = sigmas ** 2
self._gmm.precisions_cholesky_ = 1 / np.sqrt(self._gmm.covariances_)
self._gmm.fit = None // disable fit method for safety
def sample(self, size):
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 7
Instances Project Name: astroML/astroML
Commit Name: 4e70cb5fc9a9494e866ccd7d2e1a9046091b6337
Time: 2018-11-16
Author: bsipocz@gmail.com
File Name: astroML/density_estimation/gauss_mixture.py
Class Name: GaussianMixture1D
Method Name: __init__
Project Name: stratosphereips/StratosphereLinuxIPS
Commit Name: bc388862e12e27c1494078aa2409f1875ebba693
Time: 2020-06-06
Author: eldraco@gmail.com
File Name: modules/lstm-cc-detection-1/lstm-cc-detection-1.py
Class Name: Module
Method Name: convert_input_for_module
Project Name: IndicoDataSolutions/finetune
Commit Name: 0df2cf25a625d05b7590efdbbe335498b93d694d
Time: 2019-01-17
Author: madison@indico.io
File Name: finetune/target_encoders.py
Class Name: OrdinalRegressionEncoder
Method Name: fit