d7742a9476e33c9917090a4972eef688554e9d8b,features.py,,float_factor,#Any#Any#,336

Before Change



def float_factor(x, rounding):
    num2str = "{0:.{1}f}".format
    return int(re.sub("[^0-9]", "", num2str(x, rounding)))


//
// Function get_factors

After Change



def float_factor(x, rounding):
    num2str = "{0:.{1}f}".format
    fstr = re.sub("[^0-9]", "", num2str(x, rounding))
    ffactor = int(fstr) if len(fstr) > 0 else 0
    return ffactor


//
// Function get_factors
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 5

Non-data size: 5

Instances


Project Name: ScottfreeLLC/AlphaPy
Commit Name: d7742a9476e33c9917090a4972eef688554e9d8b
Time: 2016-09-09
Author: Mark.R.Conway@gmail.com
File Name: features.py
Class Name:
Method Name: float_factor


Project Name: deepmipt/DeepPavlov
Commit Name: 11db1051286a7e77ca540eab6e42ce6958b1cc6d
Time: 2018-12-25
Author: yoptar@gmail.com
File Name: setup.py
Class Name:
Method Name: readme


Project Name: pantsbuild/pants
Commit Name: 755266530b78f84fc66d239d1bfe2dc080eae363
Time: 2019-09-29
Author: ericarellano@me.com
File Name: src/python/pants/backend/project_info/tasks/idea_plugin_gen.py
Class Name: IdeaPluginGen
Method Name: get_project_name


Project Name: chartbeat-labs/textacy
Commit Name: f1da397db20721c9b1fd4d0f6840ca2d5c7d0d59
Time: 2020-03-01
Author: burtdewilde@gmail.com
File Name: textacy/preprocessing/normalize.py
Class Name:
Method Name: normalize_whitespace


Project Name: hellohaptik/chatbot_ner
Commit Name: 1a48ad2ffadfa028bf3569fdd5ba09d5e9029ba5
Time: 2018-12-20
Author: pratik.jayarao@haptik.co
File Name: ner_v2/detectors/pattern/phone_number/phone_number_detection.py
Class Name: PhoneDetector
Method Name: clean_phone_number