torch.Tensor.col_indices
- Tensor.col_indices() → IntTensor
Returns the tensor containing the column indices of the
selftensor whenselfis a sparse CSR tensor of layoutsparse_csr. Thecol_indicestensor is strictly of shape (.nnz()) and of type or . When using MKL routines such as sparse matrix multiplication, it is necessary to use indexing in order to avoid downcasting and potentially losing information.