SnapATAC icon indicating copy to clipboard operation
SnapATAC copied to clipboard

Empty Rows Error in runDiffusionMaps

Open spietrzak opened this issue 4 years ago • 2 comments

I have been working through the tutorial for analyzing 10X data using SnapATAC, but I ran into an error on the runDiffusionMaps command, saying there were empty rows in the input matrix. Here are the code and corresponding error that I see:

> snap = runDiffusionMaps(obj=snap, input.mat="bmat", num.eigs=50) Epoch: checking the inputs ... Error in runDiffusionMaps(obj = snap, input.mat = "bmat", num.eigs = 50) : input matrix contains empty rows, remove empty rows first

Does anyone know why I am getting this error or how to resolve it. I hadn't gotten any errors in the previous steps, but could something have been done wrong prior to this step that resulted in this error. Any help or advice would be much appreciated. Thank you.

spietrzak avatar Mar 09 '20 16:03 spietrzak

Update: I was able to resolve this issue (I forgot to do the barcode selection for all of my samples that I combined together, so there were probably some empty barcodes included before). However, now when I try to run it, it runs for a while, but then a box pops up saying:

R Session Aborted R encountered a fatal error. The session was terminated.

To me, it appears that there is not enough memory on my computer, as I noticed that the storage space on my computer is approaching 0 before this message pops up. Below are the code and output messages that I see when I run it before R shuts down:

> x.sp = runDiffusionMaps(obj=x.sp, input.mat="bmat", num.eigs=50)
Epoch: checking the inputs ...
Epoch: computing jaccard similarity matrix ...
Epoch: fitting regression model ...
Epoch: performing normalization ...

Is there a way to get around this issue other than to free up more space on my computer? Again, any advice would be greatly appreciated. Thank you.

spietrzak avatar Mar 10 '20 15:03 spietrzak

I'm sorry to bother you, but I have the same problem as you. How did you solve it? My code is as follows:

idx.landmark.ds = sort(sample(x = seq(nrow(x.sp_mat)), size = 10000, prob = sampling_prob)) x.landmark.sp = x.sp_mat[idx.landmark.ds,] x.query.sp = x.sp_mat[-idx.landmark.ds,] x.landmark.sp_run = runDiffusionMaps(obj= x.landmark.sp,input.mat="bmat",num.eigs=50) Epoch: checking the inputs ... Error in runDiffusionMaps(obj = x.landmark.sp, input.mat = "bmat", num.eigs = 50) : input matrix contains empty rows, remove empty rows first I am looking forward to your reply! With best wishes.

1221li avatar Nov 22 '21 14:11 1221li