HiCExplorer
HiCExplorer copied to clipboard
hicAdjustMatrix ValueError: could not convert integer scalar
Hi,
I am using the latest 3.7.2 installed via conda and I am having this error (see below) when executing
hicAdjustMatrix-3.7.2 -a keep --interIntraHandling inter -m matrix.h5 -o matrix.transRemoved.h5 --chromosomes chr2L chr2R chr3L chr3R chr4 chrX
The input matrix.h5
is an unmodified raw h5 matrix produced by hicBuildMatrix
with a bin size of 1K (note the hicexplorer version is older ie 3.6 as the matrices was generated some time ago).
The weird thing is that the error does not occur if I used a lower resolution i.e. binning at 5K generated using hicMergeMatrixBins --numBins 5
(also produced with v3.6)
Would you have an idea of the issue? Actually I am pretty sure this is not the first time I get this kind of error (I was away from HiC for a while) when using the 1K resolution but not with lower resolutions.
Traceback (most recent call last):
File "/g/funcgen/gbcs/public/software/conda/envs/hicexplorer-3.7.2/bin/hicAdjustMatrix", line 7, in <module>
main()
File "/g/funcgen/gbcs/public/software/conda/envs/hicexplorer-3.7.2/lib/python3.8/site-packages/hicexplorer/hicAdjustMatrix.py", line 197, in main
hic_matrix = adjustMatrix(args)
File "/g/funcgen/gbcs/public/software/conda/envs/hicexplorer-3.7.2/lib/python3.8/site-packages/hicexplorer/hicAdjustMatrix.py", line 177, in adjustMatrix
hic_matrix.matrix[start:end, end:] = 0
File "/g/funcgen/gbcs/public/software/conda/envs/hicexplorer-3.7.2/lib/python3.8/site-packages/scipy/sparse/_index.py", line 146, in __setitem__
self._set_arrayXarray(i, j, x)
File "/g/funcgen/gbcs/public/software/conda/envs/hicexplorer-3.7.2/lib/python3.8/site-packages/scipy/sparse/_compressed.py", line 823, in _set_arrayXarray
self._set_many(i, j, x)
File "/g/funcgen/gbcs/public/software/conda/envs/hicexplorer-3.7.2/lib/python3.8/site-packages/scipy/sparse/_compressed.py", line 910, in _set_many
ret = csr_sample_offsets(M, N, self.indptr, self.indices, n_samples,
ValueError: could not convert integer scalar
Hi @joachimwolff , I am really stuck with this. Would you be able to help pls?
could this be related to #787 ?