INNER CODE UNIT · Python
f0
idealo/image-quality-assessment · data/TID2013/get_labels.py:11
def f0(x):
return x
return [f0]
def get_max_entropy_distribution(mean):
SAMPLESPACE = np.arange(10)
features = get_features()
model = MinDivergenceModel(features, samplespace=SAMPLESPACE, algorithm='CG')
# set the desired feature expectations and fit the model
X = np.array([[mean]])
model.fit(X)
return model.probdist()