cd1a5446ce793d09f28d021c466a279301eb51f0,deslib/des/meta_des.py,METADES,select,#METADES#,294
Before Change
-------
indices : the indices of the selected base classifiers
indices = [idx for idx, _ in enumerate(competences) if competences[idx] > self.gamma]
// if no classifier was selected, use the whole pool
if len(indices) == 0:
After Change
if competences.ndim < 2:
competences = competences.reshape(1, -1)
selected_classifiers = (competences > self.selection_threshold)
// For the rows that are all False (i.e., no base classifier was selected, select all classifiers (all True)
selected_classifiers[~np.any(selected_classifiers, axis=1), :] = True
return selected_classifiers
def estimate_competence(self, query, predictions):
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 11
Instances Project Name: scikit-learn-contrib/DESlib
Commit Name: cd1a5446ce793d09f28d021c466a279301eb51f0
Time: 2018-04-01
Author: rafaelmenelau@gmail.com
File Name: deslib/des/meta_des.py
Class Name: METADES
Method Name: select
Project Name: scikit-learn-contrib/DESlib
Commit Name: cd1a5446ce793d09f28d021c466a279301eb51f0
Time: 2018-04-01
Author: rafaelmenelau@gmail.com
File Name: deslib/des/meta_des.py
Class Name: METADES
Method Name: select
Project Name: scikit-learn-contrib/DESlib
Commit Name: e25ce99878d2b5c151ed8fde92276fbb2cb338b2
Time: 2018-03-28
Author: rafaelmenelau@gmail.com
File Name: deslib/des/knop.py
Class Name: KNOP
Method Name: select
Project Name: scikit-learn-contrib/DESlib
Commit Name: e25ce99878d2b5c151ed8fde92276fbb2cb338b2
Time: 2018-03-28
Author: rafaelmenelau@gmail.com
File Name: deslib/des/knora_u.py
Class Name: KNORAU
Method Name: select