15bc4baff9c2dfa2e42947a417e45a159ab50dad,ludwig/models/modules/embedding_modules.py,EmbedSparse,__call__,#EmbedSparse#Any#Any#Any#Any#,287

Before Change


            self.initializer
        )

        multiple_hot_indexes = tf.multiply(
            input_sparse,
            tf.constant(np.array([range(len(self.vocab))], dtype=np.int32))
        )

        idx = tf.where(tf.not_equal(multiple_hot_indexes, 0))

        sparse_multiple_hot_indexes = tf.SparseTensor(

After Change



        sparse_multiple_hot_indexes = tf.SparseTensor(
            idx,
            idx[:, 1],
            tf.shape(input_sparse, out_type=tf.int64)
        )
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 4

Instances


Project Name: uber/ludwig
Commit Name: 15bc4baff9c2dfa2e42947a417e45a159ab50dad
Time: 2020-05-14
Author: w4nderlust@gmail.com
File Name: ludwig/models/modules/embedding_modules.py
Class Name: EmbedSparse
Method Name: __call__


Project Name: NifTK/NiftyNet
Commit Name: 984d17836d7a6240942cd44f2f61c92a427bb9bb
Time: 2018-04-24
Author: z.eaton-rosen@ucl.ac.uk
File Name: niftynet/layer/crop.py
Class Name: CropLayer
Method Name: layer_op


Project Name: uber/ludwig
Commit Name: 66866187ee32e7ec2f1e93cbd39a21a0afd1ccd3
Time: 2020-05-09
Author: w4nderlust@gmail.com
File Name: ludwig/models/modules/embedding_modules.py
Class Name: EmbedSparse
Method Name: call