[Bioc-devel] Rsamtools: applyPileups seg fault (!!)

Dan Gatti Dan.Gatti at jax.org
Wed Oct 1 23:08:38 CEST 2014


I'm trying to pileup some BAMs and I'm finding that certain loci in certain files produce seg faults. I've tried to find some common property, but I'm at a loss. I've selected a single locus in a single file that reproducibly produces the problem.  The BAM file and its index are on our FTP site. Here is the script and its output:

library(Rsamtools)

file = "ftp://ftp.jax.org.dgatti/M143.final.sorted.bam"
pf = PileupFiles(file)
pileupfxn = function(x) {
    x$seq
} # pileupfxn
gr = GRanges(seqnames = "chr11",
     ranges = IRanges(start = c(58109576, 58111391), width = c(1,1)))
puparam = PileupParam(minBaseQuality = 20L, what = "seq", which = gr)
pu = applyPileups(files = pf, FUN = pileupfxn, param = puparam)

*** caught segfault ***
address 0xffffffffce138f6c, cause 'memory not mapped'

Traceback:
1: .Call(.apply_pileups, extptr, names(files), space, param, FUN)
2: doTryCatch(return(expr), name, parentenv, handler)
3: tryCatchOne(expr, names, parentenv, handlers[[1L]])
4: tryCatchList(expr, classes, parentenv, handlers)
5: tryCatch({    param <- as(param, "list")    extptr <- lapply(files, .extptr)    space <- if (0L != length(param[["which"]]))         .asSpace(param[["which"]])    else NULL    param[["what"]] <- c("seq", "qual") %in% param[["what"]]    .Call(.apply_pileups, extptr, names(files), space, param,         FUN)}, error = function(err) {    stop("applyPileups: ", conditionMessage(err), call. = FALSE)})
6: applyPileups(files = pf, FUN = pileupfxn, param = puparam)
7: applyPileups(files = pf, FUN = pileupfxn, param = puparam)

And here is the sessionInfo().  I can reproduce this on Windows and Linux. I haven't tested on a Mac.

> sessionInfo()
R version 3.1.0 (2014-04-10)
Platform: x86_64-unknown-linux-gnu (64-bit)

locale:
[1] LC_CTYPE=en_US       LC_NUMERIC=C         LC_TIME=en_US
[4] LC_COLLATE=en_US     LC_MONETARY=en_US    LC_MESSAGES=en_US
[7] LC_PAPER=en_US       LC_NAME=C            LC_ADDRESS=C
[10] LC_TELEPHONE=C       LC_MEASUREMENT=en_US LC_IDENTIFICATION=C

attached base packages:
[1] parallel  stats     graphics  grDevices utils     datasets  methods
[8] base

other attached packages:
[1] Rsamtools_1.16.1     Biostrings_2.32.1    XVector_0.4.0
[4] GenomicRanges_1.16.4 GenomeInfoDb_1.0.2   IRanges_1.22.10
[7] BiocGenerics_0.10.0

loaded via a namespace (and not attached):
[1] bitops_1.0-6    stats4_3.1.0    zlibbioc_1.10.0

Any help or thoughts would be appreciated.

Thanks,
Dan

The information in this email, including attachments, may be confidential and is intended solely for the addressee(s). If you believe you received this email by mistake, please notify the sender by return email as soon as possible.

	[[alternative HTML version deleted]]



More information about the Bioc-devel mailing list