[R] does segfault mean (always) a bug?
lejeczek
peljasz at yahoo.co.uk
Wed May 6 10:56:35 CEST 2015
On 06/05/15 09:32, Martin Maechler wrote:
>>>>>> Duncan Murdoch <murdoch.duncan at gmail.com>
>>>>>> on Tue, 5 May 2015 15:36:59 -0400 writes:
> > On 05/05/2015 2:54 PM, lejeczek wrote:
> >> hi eveybody
> >>
> >> I'm trying something simple (Biocunductor packages), so
> >> simple I believe it's example from docs but I get segfault.
> >> I don't suppose incorrect scripting can cause segfault, right?
>
> > In R, a segfault always indicates a bug. What's not so clear is whether
> > it is a bug in R, a bug in a contributed package, or a bug in some
> > underlying system library.
>
> > If you can only trigger the bug when using a Bioconductor package, then
> > the first guess is that it is that package, and the maintainer of that
> > package is in the best position to track it down further. If you can
> > simplify the code to trigger it without using any contributed packages,
> > then it could well be a bug in R, and we'd like to see code to reproduce it.
> > Duncan Murdoch
>
> The bug Duncan mentions can also be in the user's R code, outside any package:
>
> If a user does what (s)he should never do, namely directly call
> .C(), .Fortran(), .Call() or similar (.Internal(), .External(),..)
> it is typically easy to trigger segfaults, and then the bug is
> in the user's R code.
>
> Variations of the above involve using the inline package, or
> other interfaces to C/C++/... code, libraries, etc: The bug may be in
> your code rather than the underlying code which is allowed to
> make strong assumptions about how it is called.
>
> Martin Maechler
>
>
not in my case, no of the above call mentioned calls is
being used, it really is very simple code (possibly with errors)
I know this is not a place to debug anything but if one
wants to have a look here it is:
library(org.Hs.eg.db)
#library(org.Mm.eg.db)
#library(org.Sc.sgd.db)
library(GOSim)
#library(GO.db)
#setEvidenceLevel(evidences="all", organism="yeast")
#setEvidenceLevel(evidences="all")
setEvidenceLevel(evidences = "all",
organism=org.Hs.egORGANISM, gomap=org.Hs.egGO)
calc.diffusion.kernel(method="diffKernelLapl", m=5,
normalization.method="sqrt", DIR="/__.aLocalStorages/1")
#calc.diffusion.kernel(method="diffKernelLLE", m=5,
normalization.method="sqrt", DIR="/__.aLocalStorages/1")
and:
...
calculating diffusion kernel 'diffKernelLLE' for ontology BP
using evidence codes 'all' (Homo sapiens) ...
Note: method with signature ‘Matrix#matrix’ chosen for
function ‘-’,
target signature ‘ddiMatrix#matrix’.
"ddiMatrix#ANY" would also be valid
*** caught segfault ***
address 0x7ffedd69e348, cause 'memory not mapped'
Traceback:
1: E %*% K %*% E
2: E %*% K %*% E
3: calc.diffusion.kernel(method = "diffKernelLLE", m = 5,
normalization.method = "sqrt", DIR = "/tmp")
aborting ...
regards
More information about the R-help
mailing list