e47c356f2f4164d0050109694d84dc955823fbf8,tpot/export_utils.py,,replace_function_calls,#Any#,192

Before Change


                                                                                                INPUT_DF=operator[2])
            if result_name != operator[2]:
                operator_text += "{OUTPUT_DF} = {INPUT_DF}.copy()\n".format(OUTPUT_DF=result_name, INPUT_DF=operator[2])
            operator_text += ("""{OUTPUT_DF}["xgbc{OPERATOR_NUM}-classification"] = xgbc{OPERATOR_NUM}.predict("""
                              """{OUTPUT_DF}.drop("class", axis=1).values)\n""").format(OUTPUT_DF=result_name,
                                                                                        OPERATOR_NUM=operator_num)

        elif operator_name == "_combine_dfs":
            operator_text += "\n// Combine two DataFrames"
            operator_text += ("\n{OUTPUT_DF} = {INPUT_DF1}.join({INPUT_DF2}[[column for column in {INPUT_DF2}.columns.values "

After Change



        elif operator_name == "_gradient_boosting":
            learning_rate = max(learning_rate, 0.0001)
            max_depth = max(max_depth, 3)

            if result_name != operator[2]:
                operator_text += "\n{OUTPUT_DF} = {INPUT_DF}.copy()".format(OUTPUT_DF=result_name, INPUT_DF=operator[2])
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 4

Non-data size: 3

Instances


Project Name: EpistasisLab/tpot
Commit Name: e47c356f2f4164d0050109694d84dc955823fbf8
Time: 2016-05-19
Author: supacoofoo@gmail.com
File Name: tpot/export_utils.py
Class Name:
Method Name: replace_function_calls


Project Name: pytorch/examples
Commit Name: 77a6ec73c53c5cc62a2ae451694537144afa5644
Time: 2016-09-14
Author: alerer@fb.com
File Name: mnist/main.py
Class Name:
Method Name: test


Project Name: ray-project/ray
Commit Name: 63594c537064d5cc47179169df6e6e6defa613d6
Time: 2021-03-25
Author: ed.nmi.oakes@gmail.com
File Name: python/ray/serve/backend_state.py
Class Name: BackendState
Method Name: _scale_backend_replicas