'Posterior probabilities of classification
This function returns posterior probabilities of classification
according to each class on an array of test vectors X.
Parameters
X : array-like, shape (n_samples, n_features)
The samples.
Returns
C : array, shape (n_samples, n_classes)
The predicted probas.'

def predict_proba(self, X):

    check_is_fitted(self, ['classes_', 'calibrated_classifiers_'])
    X = check_array(X, accept_sparse=['csc', 'csr', 'coo'], force_all_finite=False)
    mean_proba = np.zeros((X.shape[0], len(self.classes_)))
    for calibrated_classifier in self.calibrated_classifiers_:
        proba = calibrated_classifier.predict_proba(X)
        mean_proba += proba
    mean_proba /= len(self.calibrated_classifiers_)
    return mean_proba
