29f7321b64ada5e66ff4ba8e4c9d0a44fed241f4,t3f/initializers.py,,random_matrix,#Any#Any#Any#Any#,299
Before Change
tt_rank[i + 1])
tt_cores[i] = tf.random_normal(curr_core_shape, mean=mean, stddev=stddev)
return TensorTrain(tt_cores, shape, tt_rank)
def random_matrix_batch(shape, tt_rank=2, batch_size=1, mean=0., stddev=1.):
Generate a random batch of TT-matrices of given shape.
After Change
core_stddev = stddev ** (1.0 / num_dims) * var
tt = matrix_with_random_cores(shape, tt_rank=tt_rank, stddev=core_stddev)
if np.abs(mean) < 1e-8:
return tt
else:
raise NotImplementedError("non-zero mean is not supported yet")
def random_matrix_batch(shape, tt_rank=2, batch_size=1, mean=0., stddev=1.):
Generate a batch of TT-matrices with given shape, mean and stddev.
Entries of the generated matrices (in the full format) will be iid and
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 5
Instances
Project Name: Bihaqo/t3f
Commit Name: 29f7321b64ada5e66ff4ba8e4c9d0a44fed241f4
Time: 2018-01-04
Author: khrulkov.v@gmail.com
File Name: t3f/initializers.py
Class Name:
Method Name: random_matrix
Project Name: Bihaqo/t3f
Commit Name: 4257bd12136ce3a135a4fab4ad0667dfccf8368d
Time: 2017-02-03
Author: novikov@bayesgroup.ru
File Name: variables.py
Class Name:
Method Name: get_tt_variable
Project Name: Bihaqo/t3f
Commit Name: 29f7321b64ada5e66ff4ba8e4c9d0a44fed241f4
Time: 2018-01-04
Author: khrulkov.v@gmail.com
File Name: t3f/initializers.py
Class Name:
Method Name: random_tensor