I want to populate the upper triangle of a 3D tf.SparseTensor. To get the correct indices I use triu_indices
tf.SparseTensor
triu_indices
triu_indices(3, 1) <