ee602b6f68f0bdd19f449a86955697f8f0a2d54c,gluoncv/data/transforms/video.py,VideoNormalize,forward,#VideoNormalize#Any#,69

Before Change


        num_images = int(c / 3)
        clip_mean = self.mean * num_images
        clip_std = self.std * num_images
        clip_mean = nd.array(np.asarray(clip_mean).reshape((c, 1, 1)))
        clip_std = nd.array(np.asarray(clip_std).reshape((c, 1, 1)))
        return (clips - clip_mean) / clip_std

class VideoRandomHorizontalFlip(Block):

After Change


        self.std = np.asarray(std).reshape((len(std), 1, 1))

    def forward(self, clips):
        new_clips = []
        for cur_img in clips:
            new_clips.append((cur_img - self.mean) / self.std)
        return new_clips
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 5

Non-data size: 4

Instances


Project Name: dmlc/gluon-cv
Commit Name: ee602b6f68f0bdd19f449a86955697f8f0a2d54c
Time: 2019-09-21
Author: yizhu59@gmail.com
File Name: gluoncv/data/transforms/video.py
Class Name: VideoNormalize
Method Name: forward


Project Name: tryolabs/luminoth
Commit Name: 9087f87adf5983e10f5dcb88ed60b6b80ad367e8
Time: 2017-08-11
Author: gaston@Gastons-MacBook-Pro.local
File Name: luminoth/models/fasterrcnn/rpn_anchor_target_test.py
Class Name: RPNAnchorTargetTest
Method Name: setUp


Project Name: GPflow/GPflow
Commit Name: 49a385eae93032125a6718433b3ca1753aee3b1e
Time: 2017-11-02
Author: art.art.v@gmail.com
File Name: testing/test_method_equivalence.py
Class Name: TestEquivalence
Method Name: test_all


Project Name: d2l-ai/d2l-zh
Commit Name: 3393a6976ab44aad8e7390692eab3ea126ce3f7d
Time: 2018-07-19
Author: asv325@gmail.com
File Name: gluonbook/utils.py
Class Name:
Method Name:


Project Name: dmlc/gluon-nlp
Commit Name: 2c5f22199b46837b9801378ce172dcd13f125769
Time: 2018-07-17
Author: leonard@lausen.nl
File Name: gluonnlp/vocab/subwords.py
Class Name: NGramHashes
Method Name: _word_to_hashes