e25ce99878d2b5c151ed8fde92276fbb2cb338b2,deslib/des/knop.py,KNOP,select,#KNOP#Any#,137

Before Change


        // If all weights is equals to zero, it means that no classifier was selected. Hence, use all of them with equal
        // weights.
        if np.sum(weights) == 0:
            weights = np.ones(self.n_classifiers, dtype=int)

        votes = np.array([], dtype=int)
        for clf_idx, clf in enumerate(self.pool_classifiers):
            votes = np.hstack(

After Change


        indices = (competence > 0)

        // For the rows that are all False (i.e., no base classifier was selected, select all classifiers (set all True)
        indices[~np.any(indices, axis=1), :] = True
        //
        // output_profile_query = self._output_profile_transform(query)
        // weights = self.estimate_competence(output_profile_query.reshape(1, -1))
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


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: acoular/acoular
Commit Name: d6d6370cf0b7cb3d312b087ee63fc08f8f9b21ea
Time: 2020-06-02
Author: s.jekosch@tu-berlin.de
File Name: acoular/grids.py
Class Name: PolySector
Method Name: contains


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