e485b12acb290ba9bd7670179144e92ffd31d0bc,python/vmaf_quality_runner.py,VmafQualityRunner,_get_quality_scores,#VmafQualityRunner#Any#,125

Before Change


        vmaf_idx = 0
        with open(log_file_path, "rt") as log_file:
            for line in log_file.readlines():
                mo_vmaf = re.match(r"vmaf: ([0-9]+) ([0-9.]+)", line)
                if mo_vmaf:
                    cur_vmaf_idx = int(mo_vmaf.group(1))
                    assert cur_vmaf_idx == vmaf_idx
                    vmaf_scores.append(float(mo_vmaf.group(2)))
                    vmaf_idx += 1

        // add VMAF scores
        result[self.TYPE + "_scores"] = vmaf_scores

        return result

After Change


        
        repr_asset = repr(asset)
        assert repr_asset in self.asset2quality_map
        return self.asset2quality_map[repr_asset]

    def _remove_log(self, asset):
        
        Remove VmafFeatureExtractor"s log instead
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 5

Instances


Project Name: Netflix/vmaf
Commit Name: e485b12acb290ba9bd7670179144e92ffd31d0bc
Time: 2016-02-12
Author: zli@netflix.com
File Name: python/vmaf_quality_runner.py
Class Name: VmafQualityRunner
Method Name: _get_quality_scores


Project Name: polyaxon/polyaxon
Commit Name: 8d4140e264a0a47d3d690a5adc6386c027e2f8e2
Time: 2019-07-13
Author: mouradmourafiq@gmail.com
File Name: polystores/stores/azure_store.py
Class Name: AzureStore
Method Name: parse_wasbs_url


Project Name: sloria/TextBlob
Commit Name: 7ef05274835b2272b1b431d3633d0559db684197
Time: 2015-06-08
Author: jschnurr@gmail.com
File Name: textblob/translate.py
Class Name: Translator
Method Name: _get_language_from_json5