488f5cc21c564bf017994d63a782c19b2c759bb1,chainer/initializers/uniform.py,Uniform,__call__,#Uniform#Any#,32

Before Change


            assert array.dtype == self.dtype
        device = backend.get_device_from_array(array)
        if device.xp is numpy:
            array[...] = self.rng_np.uniform(
                low=-self.scale, high=self.scale, size=array.shape)
        elif device.xp is cuda.cupy:
            array[...] = self.rng_cp.uniform(
                low=-self.scale, high=self.scale, size=array.shape)
        else:

After Change


        if self.dtype is not None:
            assert array.dtype == self.dtype,\
                "{} != {}".format(array.dtype, self.dtype)
        backend.copyto(array, self.rng.uniform(
            low=-self.scale, high=self.scale,
            size=array.shape).astype(array.dtype))


class LeCunUniform(initializer.Initializer):
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 4

Non-data size: 3

Instances


Project Name: chainer/chainer
Commit Name: 488f5cc21c564bf017994d63a782c19b2c759bb1
Time: 2019-09-06
Author: nc.jky0@gmail.com
File Name: chainer/initializers/uniform.py
Class Name: Uniform
Method Name: __call__


Project Name: deepmind/dm_control
Commit Name: 3b23803f0532c228a260ccae4853f972e044cf33
Time: 2019-03-22
Author: stunya@google.com
File Name: dm_control/mujoco/engine.py
Class Name: Physics
Method Name: check_invalid_state


Project Name: scikit-image/scikit-image
Commit Name: 80a574010ad434c064afe1a3bdc523de743695c6
Time: 2021-02-10
Author: rfezzani@gmail.com
File Name: skimage/segmentation/_clear_border.py
Class Name:
Method Name: clear_border


Project Name: chainer/chainer
Commit Name: 488f5cc21c564bf017994d63a782c19b2c759bb1
Time: 2019-09-06
Author: nc.jky0@gmail.com
File Name: chainer/initializers/normal.py
Class Name: Normal
Method Name: __call__