a5ece8397b520f350e75abdb1b7bac8fbbba2d62,pycm/pycm_obj.py,ConfusionMatrix,position,#ConfusionMatrix#,792

Before Change


        
        if self.predict_vector is None or self.actual_vector is None:
            raise pycmVectorError(VECTOR_ONLY_ERROR)
        classes = set.union(set(self.predict_vector), set(self.actual_vector))
        if self.positions is None:
            positions = {self.label_map[_class] : {"TP":[], "FP":[], "TN":[], "FN":[]} for _class in classes}
            predict_vector = self.predict_vector
            actual_vector = self.actual_vector

After Change


        if self.predict_vector is None or self.actual_vector is None:
            raise pycmVectorError(VECTOR_ONLY_ERROR)
        if self.positions is None:
            classes = list(self.label_map.keys())
            positions = {self.label_map[_class] : {"TP":[], "FP":[], "TN":[], "FN":[]} for _class in classes}
            [actual_vector, predict_vector] = vector_filter(self.actual_vector, self.predict_vector)
            for index, observation in enumerate(predict_vector):
                for _class in classes:
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 5

Instances


Project Name: sepandhaghighi/pycm
Commit Name: a5ece8397b520f350e75abdb1b7bac8fbbba2d62
Time: 2020-06-25
Author: sepand.haghighi@yahoo.com
File Name: pycm/pycm_obj.py
Class Name: ConfusionMatrix
Method Name: position


Project Name: tyarkoni/pliers
Commit Name: 005968dcfbd2a8f70d8ea3957c8abba60a12492d
Time: 2018-05-15
Author: quinten.mcnamara@gmail.com
File Name: pliers/filters/video.py
Class Name: FrameSamplingFilter
Method Name: _filter


Project Name: snorkel-team/snorkel
Commit Name: 705e46d8c12fb86646ea5438e2225b5dd3912ae9
Time: 2016-08-10
Author: ajratner@gmail.com
File Name: snorkel/viewer.py
Class Name: Viewer
Method Name: __init__