NumpyTensorSpace.one

NumpyTensorSpace.one(self)[source]

Return a tensor of all ones.

Examples

>>> space = odl.rn(3)
>>> x = space.one()
>>> x
rn(3).element([ 1.,  1.,  1.])