Python: how do you store a sparse matrix using python?

前端 未结 7 1818
灰色年华
灰色年华 2021-02-06 06:17

I have got an output using sparse matrix in python, i need to store this sparse matrix in my hard disk, how can i do it? if i should create a database then how should i do?? thi

7条回答
  •  再見小時候
    2021-02-06 07:05

    For very big sparse matrices on clusters, you might use pytrilinos, it has a HDF5 interface which can dump a sparse matrix to disk, and works also if the matrix is distributed on different nodes.

    http://trilinos.sandia.gov/packages/pytrilinos/development/EpetraExt.html#input-output-classes

提交回复
热议问题