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

Before Change


        c, _, _ = clips.shape
        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):
    Randomly flip the input video clip left to right

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

class VideoRandomHorizontalFlip(Block):
    Randomly flip the images left to right with a probability.
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 7

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: dmlc/gluon-cv
Commit Name: ee602b6f68f0bdd19f449a86955697f8f0a2d54c
Time: 2019-09-21
Author: yizhu59@gmail.com
File Name: gluoncv/data/transforms/video.py
Class Name: VideoMultiScaleCrop
Method Name: forward


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