2974b94deea2dd84ec90059f946159bbd8b1fc43,gpflow/config/__config__.py,,set_default_int,#Any#,54

Before Change



def set_default_int(value_type):
    try:
        tf.as_dtype(value_type)  // Test input value that it is eligable type.
        __config._int = value_type
    except TypeError:
        raise TypeError("Expected tf or np dtype argument")

After Change



def set_default_int(value_type):
    try:
        tf_dtype = tf.as_dtype(value_type)  // Test that it"s a tensorflow-valid dtype
    except TypeError:
        raise TypeError(f"{value_type} is not a valid tf or np dtype")
    if not tf_dtype.is_integer:
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 5

Non-data size: 3

Instances


Project Name: GPflow/GPflow
Commit Name: 2974b94deea2dd84ec90059f946159bbd8b1fc43
Time: 2019-10-07
Author: st--@users.noreply.github.com
File Name: gpflow/config/__config__.py
Class Name:
Method Name: set_default_int


Project Name: tensorflow/mesh
Commit Name: 3a54e3af7fc0a9417d379d5e6ff12eb45795f9c4
Time: 2019-03-09
Author: noam@google.com
File Name: examples/transformer_standalone.py
Class Name:
Method Name: my_model_fn


Project Name: OpenNMT/OpenNMT-tf
Commit Name: c141e570011e7adf3634bd65a3e7de30d8fbdca2
Time: 2018-10-18
Author: guillaumekln@users.noreply.github.com
File Name: opennmt/utils/checkpoint.py
Class Name:
Method Name: _create_checkpoint_from_variables


Project Name: OpenNMT/OpenNMT-tf
Commit Name: 6a1179c46ced0d0238911b00e61fc6079c7568c7
Time: 2018-10-17
Author: guillaumekln@users.noreply.github.com
File Name: opennmt/tests/checkpoint_test.py
Class Name: CheckpointTest
Method Name: _generateCheckpoint


Project Name: GPflow/GPflow
Commit Name: 2974b94deea2dd84ec90059f946159bbd8b1fc43
Time: 2019-10-07
Author: st--@users.noreply.github.com
File Name: gpflow/config/__config__.py
Class Name:
Method Name: set_default_float