23ee13aef276de7ad726eb4825e201d3c885c008,entity2rec/entity2rec.py,Entity2Rec,content_similarities,#Entity2Rec#,63

Before Change


                                                -1))  // append a list of property-specific scores, skip feedback

        if len(sims) == 0:  // no content properties for the item
            sims = 0.5 * np.ones(len(self.properties) - 1)
            return sims

        return np.mean(sims, axis=0)  // return a list of averages of property-specific scores

After Change



            if prop != "feedback":

                sims_prop = []

                for past_item in items_liked_by_user:

                    sims_prop.append(self.relatedness_score(prop, past_item, item))
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 4

Non-data size: 4

Instances


Project Name: D2KLab/entity2rec
Commit Name: 23ee13aef276de7ad726eb4825e201d3c885c008
Time: 2018-01-25
Author: enricopalumbo0@gmail.com
File Name: entity2rec/entity2rec.py
Class Name: Entity2Rec
Method Name: content_similarities


Project Name: scikit-image/scikit-image
Commit Name: 1cc277630f2381f2ba0f01dcf833801a830f5c3b
Time: 2020-08-04
Author: rfezzani@gmail.com
File Name: skimage/metrics/_contingency_table.py
Class Name:
Method Name: contingency_table


Project Name: scikit-learn-contrib/DESlib
Commit Name: 65cce49dcac95a195c1c3cb2283a4f4dbda981ec
Time: 2018-03-25
Author: rafaelmenelau@gmail.com
File Name: deslib/tests/des/test_knop.py
Class Name:
Method Name: test_fit


Project Name: scikit-learn-contrib/DESlib
Commit Name: 65cce49dcac95a195c1c3cb2283a4f4dbda981ec
Time: 2018-03-25
Author: rafaelmenelau@gmail.com
File Name: deslib/tests/test_base.py
Class Name:
Method Name: test_preprocess_dsel_scores