eric-haibin-lin commented on issue #8817: Creating a monodimensional sparse array returns an error URL: https://github.com/apache/incubator-mxnet/issues/8817#issuecomment-347310424 Thanks for reporting. I think we can add additional logic to handle such case. I tried scipy.sparse as follows: ``` >>> np.ones((10)) array([ 1., 1., 1., 1., 1., 1., 1., 1., 1., 1.]) >>> a = np.ones((10)) >>> a.shape (10,) >>> import scipy.sparse as spsp >>> spsp.csr_matrix(a) <1x10 sparse matrix of type '<type 'numpy.float64'>' with 10 stored elements in Compressed Sparse Row format> ``` Instead of converting (10) to (10,1), I think (1,10) will be more appropriate for CSR since it expects large number of columns.
---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: us...@infra.apache.org With regards, Apache Git Services