Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Error in ImputeKNN #313

Open
kangjiajinlong opened this issue Jun 11, 2024 · 0 comments
Open

Error in ImputeKNN #313

kangjiajinlong opened this issue Jun 11, 2024 · 0 comments

Comments

@kangjiajinlong
Copy link

kangjiajinlong commented Jun 11, 2024

Dear rliger team,

I am using rliger and following this tutorial https://welch-lab.github.io/liger/articles/Integrating_scRNA_and_scATAC_data.html. I followed the example code and ran imputeKNN as shown in section 10 of the tutorial. However, I received this error:

ℹ Imputing 1 query dataset: "rna"
ℹ from reference dataset: "atac"
*** caught segfault ***
address 0xffffffffdaf002e0, cause 'memory not mapped'

Traceback:
1: referenceRawData %% weights
2: referenceRawData %
% weights
3: imputeKNN(obj.liger, reference = "atac", queries = "rna")
An irrecoverable exception occurred. R is aborting now ...

The code I am using is as follows:

obj.liger <- normalizePeak(obj.liger)
rawPeakList <- lapply(datasets(obj.liger)["atac"], slot, "rawPeak")
peakliger <- createLiger(rawPeakList)
rm(rawPeakList)
gc()
peakliger <- normalize(peakliger)

#Transfer the cluster labels from the original object to the new temporary object for marker calling
peakliger$cluster <- cellMeta(obj.liger, "leiden_cluster", useDatasets = "atac")
defaultCluster(peakliger) <- "cluster"
peak.pseudobulk <- runMarkerDEG(peakliger,conditionBy="cluster",method="pseudoBulk")
rm(peakliger)
gc()
#Retain only peaks showing differential accessibility across our set of joint clusters
peak.pseudobulk.sig <- peak.pseudobulk %>% filter(padj < 0.05, logFC > 2)
peaks.sel <- unique(peak.pseudobulk.sig$feature)
rawPeak(obj.liger, "atac") <- rawPeak(obj.liger, "atac")[peaks.sel,]
obj.liger <- normalizePeak(obj.liger)
obj.liger <- imputeKNN(obj.liger, reference = "atac", queries = "rna")

I am running these commands on a computing cluster with 32 cores and 1.2T memory. Could you kindly help resolve this issue? Thank you for your help.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant