public SparseTensor getOldKeyIndicatorTensor ( ) { double [ ] values = new double [ oldKeyNums . length ] ; Arrays . fill ( values , 1.0 ) ; return SparseTensor . fromUnorderedKeyValues ( oldTensor . getDimensionNumbers ( ) , oldTensor . getDimensionSizes ( ) , oldKeyNums , values ) ; }
Gets a tensor of indicator variables for the old key values in this . The returned tensor has value 1 for all keys in this and 0 for all other keys .