2404f0a12c3b2463027c5d9fd5d3a6f42f9128b5,mir_eval/util.py,,filter_kwargs,#Any#,702

Before Change


    function_args = inspect.getargspec(function).args
    // Construct a dict of those kwargs which appear in the function
    filtered_kwargs = {}
    for kwarg, value in kwargs.items():
        if kwarg in function_args:
            filtered_kwargs[kwarg] = value
    // Call the function with the supplied args and the filtered kwarg dict
    return function(*args, **filtered_kwargs)

After Change


    function_args = inspect.getargspec(function).args
    // Construct a dict of those kwargs which appear in the function
    filtered_kwargs = {}
    for kwarg, value in list(kwargs.items()):
        if kwarg in function_args:
            filtered_kwargs[kwarg] = value
    // Call the function with the supplied args and the filtered kwarg dict
    return function(*args, **filtered_kwargs)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 37

Non-data size: 5

Instances


Project Name: craffel/mir_eval
Commit Name: 2404f0a12c3b2463027c5d9fd5d3a6f42f9128b5
Time: 2015-04-28
Author: nils.werner@gmail.com
File Name: mir_eval/util.py
Class Name:
Method Name: filter_kwargs


Project Name: Qiskit/qiskit-aqua
Commit Name: b8f865eb3a9870c68d175d0f75f765d209ac97a5
Time: 2020-09-29
Author: 62334182+adekusar-drl@users.noreply.github.com
File Name: qiskit/aqua/components/optimizers/powell.py
Class Name: POWELL
Method Name: __init__


Project Name: Qiskit/qiskit-aqua
Commit Name: b8f865eb3a9870c68d175d0f75f765d209ac97a5
Time: 2020-09-29
Author: 62334182+adekusar-drl@users.noreply.github.com
File Name: qiskit/aqua/components/optimizers/cobyla.py
Class Name: COBYLA
Method Name: __init__


Project Name: sahana/eden
Commit Name: 73832d4852e0d51971ee77d71a3acd7536a4ce2d
Time: 2020-04-13
Author: fran@aidiq.com
File Name: static/scripts/tools/mergejs.py
Class Name:
Method Name: run


Project Name: enthought/chaco
Commit Name: 665e6f9d6fab1eebcec53ca4d1adcf4265cfbeb6
Time: 2016-06-06
Author: pankaj@enthought.com
File Name: examples/demo/canvas/mptools.py
Class Name: MPRangeSelection
Method Name: _convert_to_axis


Project Name: hyperopt/hyperopt
Commit Name: a4d27f15187c5d803d8e3bf52e27ad008023c47b
Time: 2016-11-13
Author: max.pumperla@googlemail.com
File Name: hyperopt/vectorize.py
Class Name:
Method Name: idxs_map


Project Name: hyperopt/hyperopt
Commit Name: 8a58ed73645ed15ef5a43d21ed5ddcb84b524d34
Time: 2016-11-13
Author: max.pumperla@googlemail.com
File Name: hyperopt/pyll_utils.py
Class Name:
Method Name: _remove_allpaths


Project Name: Qiskit/qiskit-aqua
Commit Name: b8f865eb3a9870c68d175d0f75f765d209ac97a5
Time: 2020-09-29
Author: 62334182+adekusar-drl@users.noreply.github.com
File Name: qiskit/aqua/components/optimizers/slsqp.py
Class Name: SLSQP
Method Name: __init__


Project Name: f90/Wave-U-Net
Commit Name: c102b544634055a89a007ed8555afc725bc044d9
Time: 2019-07-22
Author: daniel@dstoller.net
File Name: Utils.py
Class Name:
Method Name: random_amplify


Project Name: interactiveaudiolab/nussl
Commit Name: 1305409976d86e6e6aa30786585fdc375cc999a4
Time: 2018-11-20
Author: nsnshelly@gmail.com
File Name: nussl/core/audio_signal.py
Class Name: AudioSignal
Method Name: _from_json_helper


Project Name: ScottfreeLLC/AlphaPy
Commit Name: 73abb535ad01d17e524aba4b434b3d430c424140
Time: 2017-05-17
Author: raliclo@gmail.com
File Name: alphapy/optimize.py
Class Name:
Method Name: hyper_grid_search


Project Name: quadrismegistus/prosodic
Commit Name: 7a6f7c226deb397b9d81b40cfa517573f2c96ee6
Time: 2019-06-02
Author: ryan.heuser@gmail.com
File Name: lib/MeterPosition.py
Class Name: MeterPosition
Method Name: posfeats


Project Name: keras-team/keras
Commit Name: 1629f7f35becfd4d4350ff5b366998609414f830
Time: 2015-04-15
Author: francois.chollet@gmail.com
File Name: keras/preprocessing/text.py
Class Name: Tokenizer
Method Name: fit_on_texts


Project Name: Qiskit/qiskit-aqua
Commit Name: b8f865eb3a9870c68d175d0f75f765d209ac97a5
Time: 2020-09-29
Author: 62334182+adekusar-drl@users.noreply.github.com
File Name: qiskit/aqua/components/optimizers/p_bfgs.py
Class Name: P_BFGS
Method Name: __init__


Project Name: Qiskit/qiskit-aqua
Commit Name: 5988dfef141ae27d90758ae725e29355e8a4a4dd
Time: 2021-01-14
Author: mirotomasik@gmail.com
File Name: qiskit/aqua/components/optimizers/spsa.py
Class Name: SPSA
Method Name: __init__


Project Name: kkroening/ffmpeg-python
Commit Name: 662c56eb5b228b7fbf301035c074749dc9eced29
Time: 2017-07-06
Author: karlk@kralnet.us
File Name: ffmpeg/nodes.py
Class Name: Node
Method Name: __get_incoming_edge_map


Project Name: quadrismegistus/prosodic
Commit Name: 7a6f7c226deb397b9d81b40cfa517573f2c96ee6
Time: 2019-06-02
Author: ryan.heuser@gmail.com
File Name: lib/MeterPosition.py
Class Name: MeterPosition
Method Name: __copy__


Project Name: f90/Wave-U-Net
Commit Name: c102b544634055a89a007ed8555afc725bc044d9
Time: 2019-07-22
Author: daniel@dstoller.net
File Name: Utils.py
Class Name:
Method Name: crop_sample


Project Name: interactiveaudiolab/nussl
Commit Name: 1305409976d86e6e6aa30786585fdc375cc999a4
Time: 2018-11-20
Author: nsnshelly@gmail.com
File Name: nussl/separation/mask_separation_base.py
Class Name: MaskSeparationBaseDecoder
Method Name: _json_separation_decoder


Project Name: quadrismegistus/prosodic
Commit Name: 7a6f7c226deb397b9d81b40cfa517573f2c96ee6
Time: 2019-06-02
Author: ryan.heuser@gmail.com
File Name: lib/Parse.py
Class Name: Parse
Method Name: __copy__


Project Name: keras-team/keras
Commit Name: 1629f7f35becfd4d4350ff5b366998609414f830
Time: 2015-04-15
Author: francois.chollet@gmail.com
File Name: keras/preprocessing/text.py
Class Name: Tokenizer
Method Name: sequences_to_matrix


Project Name: fxsjy/jieba
Commit Name: 1152db7736d3f3296d7b90ff31756b8862091519
Time: 2015-02-15
Author: zh.milo@gmail.com
File Name: jieba/analyse/textrank.py
Class Name: UndirectWeightedGraph
Method Name: rank


Project Name: austin-taylor/flare
Commit Name: e4c160a019cb84c7fc5299345766727797ece4e1
Time: 2017-07-08
Author: github@austintaylor.io
File Name: flare/data_science/markov_model.py
Class Name: MarkovModel
Method Name: __normalize


Project Name: Qiskit/qiskit-aqua
Commit Name: b8f865eb3a9870c68d175d0f75f765d209ac97a5
Time: 2020-09-29
Author: 62334182+adekusar-drl@users.noreply.github.com
File Name: qiskit/aqua/components/optimizers/nlopts/nloptimizer.py
Class Name: NLoptOptimizer
Method Name: __init__


Project Name: ScottfreeLLC/AlphaPy
Commit Name: 73abb535ad01d17e524aba4b434b3d430c424140
Time: 2017-05-17
Author: raliclo@gmail.com
File Name: alphapy/sport_flow.py
Class Name:
Method Name: generate_delta_data


Project Name: ScottfreeLLC/AlphaPy
Commit Name: 73abb535ad01d17e524aba4b434b3d430c424140
Time: 2017-05-17
Author: raliclo@gmail.com
File Name: alphapy/sport_flow.py
Class Name:
Method Name: insert_model_data


Project Name: HDI-Project/ATM
Commit Name: a3c7a69bc422531dda3a17026020928c575bbd55
Time: 2018-02-12
Author: bcyphers@mit.edu
File Name: atm/encoder.py
Class Name: DataEncoder
Method Name: transform


Project Name: SheffieldML/GPy
Commit Name: 7eff1d984f2019ba56a799234c961b2354ed85b0
Time: 2015-03-02
Author: michael.p.croucher@googlemail.com
File Name: GPy/core/parameterization/index_operations.py
Class Name: ParameterIndexOperations
Method Name: shift_left


Project Name: kkroening/ffmpeg-python
Commit Name: 4640adabe0df764d22bfeaceb663f8327d2de9f1
Time: 2017-07-12
Author: karlk@kralnet.us
File Name: ffmpeg/nodes.py
Class Name: FilterNode
Method Name: _get_filter


Project Name: Qiskit/qiskit-aqua
Commit Name: b8f865eb3a9870c68d175d0f75f765d209ac97a5
Time: 2020-09-29
Author: 62334182+adekusar-drl@users.noreply.github.com
File Name: qiskit/aqua/components/optimizers/tnc.py
Class Name: TNC
Method Name: __init__


Project Name: Qiskit/qiskit-aqua
Commit Name: b8f865eb3a9870c68d175d0f75f765d209ac97a5
Time: 2020-09-29
Author: 62334182+adekusar-drl@users.noreply.github.com
File Name: qiskit/aqua/components/optimizers/nft.py
Class Name: NFT
Method Name: __init__


Project Name: interactiveaudiolab/nussl
Commit Name: 1305409976d86e6e6aa30786585fdc375cc999a4
Time: 2018-11-20
Author: nsnshelly@gmail.com
File Name: nussl/core/audio_signal.py
Class Name: AudioSignal
Method Name: _to_json_helper


Project Name: Qiskit/qiskit-aqua
Commit Name: b8f865eb3a9870c68d175d0f75f765d209ac97a5
Time: 2020-09-29
Author: 62334182+adekusar-drl@users.noreply.github.com
File Name: qiskit/aqua/components/optimizers/l_bfgs_b.py
Class Name: L_BFGS_B
Method Name: __init__


Project Name: Qiskit/qiskit-aqua
Commit Name: b8f865eb3a9870c68d175d0f75f765d209ac97a5
Time: 2020-09-29
Author: 62334182+adekusar-drl@users.noreply.github.com
File Name: qiskit/aqua/components/optimizers/cg.py
Class Name: CG
Method Name: __init__


Project Name: biocore/scikit-bio
Commit Name: 2c5c4a0e7994f4913fcdd706f4a5aa47c7838562
Time: 2014-05-08
Author: yoshiki89@gmail.com
File Name: skbio/core/genetic_code.py
Class Name:
Method Name:


Project Name: enthought/chaco
Commit Name: 665e6f9d6fab1eebcec53ca4d1adcf4265cfbeb6
Time: 2016-06-06
Author: pankaj@enthought.com
File Name: examples/demo/canvas/mptools.py
Class Name: MPDragZoom
Method Name: _convert_to_axis


Project Name: Qiskit/qiskit-aqua
Commit Name: b8f865eb3a9870c68d175d0f75f765d209ac97a5
Time: 2020-09-29
Author: 62334182+adekusar-drl@users.noreply.github.com
File Name: qiskit/aqua/components/optimizers/nelder_mead.py
Class Name: NELDER_MEAD
Method Name: __init__