Quantcast

debug vs regular mode

classic Classic list List threaded Threaded
12 messages Options
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

debug vs regular mode

Zhang, Peng
Dear all,

I had a R segmentation fault, and then invoked debug mode and ran step
by step.

When I reached "terms(Y~X1*X2*...*X16)", I would then have
"segmentation" fault. However, if I just ran this under regular "R
interactive" mode, it would be fine though taking long time.

My questions are:
1. Is there a known limit of terms for a formula?
2. Why does the same function behave differently under debug and regular
mode?

Thank you!

Best,
Peng
**********************************************************
Electronic Mail is not secure, may not be read every day, and should not be used for urgent or sensitive issues

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: debug vs regular mode

David Winsemius

On Aug 9, 2012, at 4:56 PM, Zhang, Peng wrote:

> Dear all,
>
> I had a R segmentation fault, and then invoked debug mode and ran step
> by step.
>
> When I reached "terms(Y~X1*X2*...*X16)", I would then have
> "segmentation" fault. However, if I just ran this under regular "R
> interactive" mode, it would be fine though taking long time.
>
> My questions are:
> 1. Is there a known limit of terms for a formula?

I think so. I seem to remember it was something around 500 characters,  
but was raised a couple of years ago.

This is a 2010 extract of a posting by the indomitable Prof Ripley:

"R-devel:
• The previously almost undocumented limit of 256 bytes on a symbol  
name has been raised to 10,000 bytes (a sanity check). Long symbol  
names can sometimes occur when deparsing expressions (for example, in  
model.frame).  "

Found with a MarkMail search with this strategy:

list:org.r-project.r-devel maximum length of formula



Subject:Re: [Rd] model.frame problem

From:Prof Brian Ripley ([hidden email])

Date:Nov 3, 2010 1:37:50 pm

List:org.r-project.r-devel


> 2. Why does the same function behave differently under debug and  
> regular
> mode?

I cannot help you there.

--

David Winsemius, MD
Alameda, CA, USA

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: debug vs regular mode

Michael Weylandt


On Aug 9, 2012, at 9:14 PM, David Winsemius <[hidden email]> wrote:

>
> On Aug 9, 2012, at 4:56 PM, Zhang, Peng wrote:
>
>> Dear all,
>>
>> I had a R segmentation fault, and then invoked debug mode and ran step
>> by step.
>
>
>> 2. Why does the same function behave differently under debug and regular
>> mode?
>
> I cannot help you there.
>

Though a reproducible segfault is certainly worth a bug report if you can do so, in debug or regular modes.

You may wish to search stackoverflow for tips on how to make a great reproducible example in R.

Michael
______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: debug vs regular mode

Zhang, Peng
Thanks to both for your reply.

library(glmulti)
testdata = cbind(Y=rnorm(100), data.frame(matrix(rnorm(100*50), ncol = 50)))
glmulti(Y~(X1+X2+X3+X4+X5+X6+X7+X8+X9+X10+X11+X12+X13+X14+X15)*X16, data
= testdata, level = 2)

This is reproducible to get a segmentation fault. But I have troubles to
extract the exact information from this S4 class to make a simpler
example because of my limited knowledge on S4 class. The author of the
package is busy at the moment, and does not have time to look into it.

Peng

On 08/09/2012 10:25 PM, R. Michael Weylandt <[hidden email]>
wrote:

>
> On Aug 9, 2012, at 9:14 PM, David Winsemius <[hidden email]> wrote:
>
>> On Aug 9, 2012, at 4:56 PM, Zhang, Peng wrote:
>>
>>> Dear all,
>>>
>>> I had a R segmentation fault, and then invoked debug mode and ran step
>>> by step.
>>
>>> 2. Why does the same function behave differently under debug and regular
>>> mode?
>> I cannot help you there.
>>
> Though a reproducible segfault is certainly worth a bug report if you can do so, in debug or regular modes.
>
> You may wish to search stackoverflow for tips on how to make a great reproducible example in R.
>
> Michael
**********************************************************
Electronic Mail is not secure, may not be read every day, and should not be used for urgent or sensitive issues

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: debug vs regular mode

Henric (Nilsson) Winell
On 2012-08-10 06:10, Zhang, Peng wrote:

> Thanks to both for your reply.
>
> library(glmulti)
> testdata = cbind(Y=rnorm(100), data.frame(matrix(rnorm(100*50), ncol = 50)))
> glmulti(Y~(X1+X2+X3+X4+X5+X6+X7+X8+X9+X10+X11+X12+X13+X14+X15)*X16, data
> = testdata, level = 2)
>
> This is reproducible to get a segmentation fault.

There's some information missing here, notably the output from
'sessionInfo()', but I guess this is under GNU/Linux.  I can confirm a
seg. fault under Fedora FC17 x86_64.

Under Windows 7 64-bit, however, we get some further info:

 > library("glmulti")
Loading required package: rJava
 > testdata = cbind(Y=rnorm(100), data.frame(matrix(rnorm(100*50), ncol
= 50)))
 > glmulti(Y~(X1+X2+X3+X4+X5+X6+X7+X8+X9+X10+X11+X12+X13+X14+X15)*X16, data
+ = testdata, level = 2)
Initialization...
Error in .jnew("glmulti/ModelGenerator", y, .jarray(xc), .jarray(xq),  :
   java.lang.ArrayIndexOutOfBoundsException: 15
 >
 > sessionInfo()
R version 2.15.1 Patched (2012-08-06 r60178)
Platform: x86_64-w64-mingw32/x64 (64-bit)

locale:
[1] LC_COLLATE=Swedish_Sweden.1252  LC_CTYPE=Swedish_Sweden.1252
[3] LC_MONETARY=Swedish_Sweden.1252 LC_NUMERIC=C
[5] LC_TIME=Swedish_Sweden.1252

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

other attached packages:
[1] glmulti_1.0.4 rJava_0.9-3
 >

So, this doesn't seem to be a bug in R and is thus likely to need the
attention of the 'glmulti' package's maintainer.


HTH,
Henric



> But I have troubles to
> extract the exact information from this S4 class to make a simpler
> example because of my limited knowledge on S4 class. The author of the
> package is busy at the moment, and does not have time to look into it.
>
> Peng
>
> On 08/09/2012 10:25 PM, R. Michael Weylandt <[hidden email]>
> wrote:
>>
>> On Aug 9, 2012, at 9:14 PM, David Winsemius <[hidden email]> wrote:
>>
>>> On Aug 9, 2012, at 4:56 PM, Zhang, Peng wrote:
>>>
>>>> Dear all,
>>>>
>>>> I had a R segmentation fault, and then invoked debug mode and ran step
>>>> by step.
>>>
>>>> 2. Why does the same function behave differently under debug and regular
>>>> mode?
>>> I cannot help you there.
>>>
>> Though a reproducible segfault is certainly worth a bug report if you can do so, in debug or regular modes.
>>
>> You may wish to search stackoverflow for tips on how to make a great reproducible example in R.
>>
>> Michael
> **********************************************************
> Electronic Mail is not secure, may not be read every day, and should not be used for urgent or sensitive issues
>
> ______________________________________________
> [hidden email] mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: debug vs regular mode

Zhang, Peng
You are right. I am running Arch Linux. However, I obtained a
segmentation directly, so didn't know where to find the bug??

 >  library("glmulti")
Loading required package: rJava
 > testdata = cbind(Y=rnorm(100), data.frame(matrix(rnorm(100*50), ncol
= 50)))
 > glmulti(Y~(X1+X2+X3+X4+X5+X6+X7+X8+X9+X10+X11+X12+X13+X14+X15)*X16,
data= testdata, level = 2)
Segmentation fault

Is this information "Error in .jnew("glmulti/ModelGenerator", y,
.jarray(xc), .jarray(xq),  : java.lang.ArrayIndexOutOfBoundsException:
15" only in Windows, or did you see it under Fedora as well?

Thank you!

Peng

BTW:

$ uname -a
Linux Precision 3.4.7-1-ARCH #1 SMP PREEMPT Sun Jul 29 22:02:56 CEST
2012 x86_64 GNU/Linux

 > sessionInfo()
R version 2.15.1 (2012-06-22)
Platform: x86_64-unknown-linux-gnu (64-bit)

locale:
  [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C
  [3] LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8
  [5] LC_MONETARY=en_US.UTF-8    LC_MESSAGES=en_US.UTF-8
  [7] LC_PAPER=C                 LC_NAME=C
  [9] LC_ADDRESS=C               LC_TELEPHONE=C
[11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C

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


On 08/10/2012 09:25 AM, Henric (Nilsson) Winell wrote:

> On 2012-08-10 06:10, Zhang, Peng wrote:
>
>> Thanks to both for your reply.
>>
>> library(glmulti)
>> testdata = cbind(Y=rnorm(100), data.frame(matrix(rnorm(100*50), ncol
>> = 50)))
>> glmulti(Y~(X1+X2+X3+X4+X5+X6+X7+X8+X9+X10+X11+X12+X13+X14+X15)*X16, data
>> = testdata, level = 2)
>>
>> This is reproducible to get a segmentation fault.
>
> There's some information missing here, notably the output from
> 'sessionInfo()', but I guess this is under GNU/Linux.  I can confirm a
> seg. fault under Fedora FC17 x86_64.
>
> Under Windows 7 64-bit, however, we get some further info:
>
> > library("glmulti")
> Loading required package: rJava
> > testdata = cbind(Y=rnorm(100), data.frame(matrix(rnorm(100*50), ncol
> = 50)))
> > glmulti(Y~(X1+X2+X3+X4+X5+X6+X7+X8+X9+X10+X11+X12+X13+X14+X15)*X16,
> data
> + = testdata, level = 2)
> Initialization...
> Error in .jnew("glmulti/ModelGenerator", y, .jarray(xc), .jarray(xq),  :
>   java.lang.ArrayIndexOutOfBoundsException: 15
> >
> > sessionInfo()
> R version 2.15.1 Patched (2012-08-06 r60178)
> Platform: x86_64-w64-mingw32/x64 (64-bit)
>
> locale:
> [1] LC_COLLATE=Swedish_Sweden.1252  LC_CTYPE=Swedish_Sweden.1252
> [3] LC_MONETARY=Swedish_Sweden.1252 LC_NUMERIC=C
> [5] LC_TIME=Swedish_Sweden.1252
>
> attached base packages:
> [1] stats     graphics  grDevices utils     datasets  methods base
>
> other attached packages:
> [1] glmulti_1.0.4 rJava_0.9-3
> >
>
> So, this doesn't seem to be a bug in R and is thus likely to need the
> attention of the 'glmulti' package's maintainer.
>
>
> HTH,
> Henric
>
>
>
>> But I have troubles to
>> extract the exact information from this S4 class to make a simpler
>> example because of my limited knowledge on S4 class. The author of the
>> package is busy at the moment, and does not have time to look into it.
>>
>> Peng
>>
>> On 08/09/2012 10:25 PM, R. Michael Weylandt <[hidden email]>
>> wrote:
>>>
>>> On Aug 9, 2012, at 9:14 PM, David Winsemius <[hidden email]>
>>> wrote:
>>>
>>>> On Aug 9, 2012, at 4:56 PM, Zhang, Peng wrote:
>>>>
>>>>> Dear all,
>>>>>
>>>>> I had a R segmentation fault, and then invoked debug mode and ran
>>>>> step
>>>>> by step.
>>>>
>>>>> 2. Why does the same function behave differently under debug and
>>>>> regular
>>>>> mode?
>>>> I cannot help you there.
>>>>
>>> Though a reproducible segfault is certainly worth a bug report if
>>> you can do so, in debug or regular modes.
>>>
>>> You may wish to search stackoverflow for tips on how to make a great
>>> reproducible example in R.
>>>
>>> Michael
>> **********************************************************
>> Electronic Mail is not secure, may not be read every day, and should
>> not be used for urgent or sensitive issues
>>
>> ______________________________________________
>> [hidden email] mailing list
>> https://stat.ethz.ch/mailman/listinfo/r-help
>> PLEASE do read the posting guide
>> http://www.R-project.org/posting-guide.html
>> and provide commented, minimal, self-contained, reproducible code.
>>
>
**********************************************************
Electronic Mail is not secure, may not be read every day, and should not be used for urgent or sensitive issues

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: debug vs regular mode

Henric (Nilsson) Winell
On 2012-08-10 15:42, Zhang, Peng wrote:

> You are right. I am running Arch Linux. However, I obtained a
> segmentation directly, so didn't know where to find the bug??
>
>   >  library("glmulti")
> Loading required package: rJava
>   > testdata = cbind(Y=rnorm(100), data.frame(matrix(rnorm(100*50), ncol
> = 50)))
>   > glmulti(Y~(X1+X2+X3+X4+X5+X6+X7+X8+X9+X10+X11+X12+X13+X14+X15)*X16,
> data= testdata, level = 2)
> Segmentation fault
>
> Is this information "Error in .jnew("glmulti/ModelGenerator", y,
> jarray(xc), .jarray(xq),  : java.lang.ArrayIndexOutOfBoundsException:
> 15" only in Windows, or did you see it under Fedora as well?

Windows only.  Fedora just returned "Segmentation fault".


//Henric



>
> Thank you!
>
> Peng
>
> BTW:
>
> $ uname -a
> Linux Precision 3.4.7-1-ARCH #1 SMP PREEMPT Sun Jul 29 22:02:56 CEST
> 2012 x86_64 GNU/Linux
>
>   > sessionInfo()
> R version 2.15.1 (2012-06-22)
> Platform: x86_64-unknown-linux-gnu (64-bit)
>
> locale:
>    [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C
>    [3] LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8
>    [5] LC_MONETARY=en_US.UTF-8    LC_MESSAGES=en_US.UTF-8
>    [7] LC_PAPER=C                 LC_NAME=C
>    [9] LC_ADDRESS=C               LC_TELEPHONE=C
> [11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C
>
> attached base packages:
> [1] stats     graphics  grDevices utils     datasets  methods base
>
>
> On 08/10/2012 09:25 AM, Henric (Nilsson) Winell wrote:
>> On 2012-08-10 06:10, Zhang, Peng wrote:
>>
>>> Thanks to both for your reply.
>>>
>>> library(glmulti)
>>> testdata = cbind(Y=rnorm(100), data.frame(matrix(rnorm(100*50), ncol
>>> = 50)))
>>> glmulti(Y~(X1+X2+X3+X4+X5+X6+X7+X8+X9+X10+X11+X12+X13+X14+X15)*X16, data
>>> = testdata, level = 2)
>>>
>>> This is reproducible to get a segmentation fault.
>>
>> There's some information missing here, notably the output from
>> 'sessionInfo()', but I guess this is under GNU/Linux.  I can confirm a
>> seg. fault under Fedora FC17 x86_64.
>>
>> Under Windows 7 64-bit, however, we get some further info:
>>
>>> library("glmulti")
>> Loading required package: rJava
>>> testdata = cbind(Y=rnorm(100), data.frame(matrix(rnorm(100*50), ncol
>> = 50)))
>>> glmulti(Y~(X1+X2+X3+X4+X5+X6+X7+X8+X9+X10+X11+X12+X13+X14+X15)*X16,
>> data
>> + = testdata, level = 2)
>> Initialization...
>> Error in .jnew("glmulti/ModelGenerator", y, .jarray(xc), .jarray(xq),  :
>>    java.lang.ArrayIndexOutOfBoundsException: 15
>>>
>>> sessionInfo()
>> R version 2.15.1 Patched (2012-08-06 r60178)
>> Platform: x86_64-w64-mingw32/x64 (64-bit)
>>
>> locale:
>> [1] LC_COLLATE=Swedish_Sweden.1252  LC_CTYPE=Swedish_Sweden.1252
>> [3] LC_MONETARY=Swedish_Sweden.1252 LC_NUMERIC=C
>> [5] LC_TIME=Swedish_Sweden.1252
>>
>> attached base packages:
>> [1] stats     graphics  grDevices utils     datasets  methods base
>>
>> other attached packages:
>> [1] glmulti_1.0.4 rJava_0.9-3
>>>
>>
>> So, this doesn't seem to be a bug in R and is thus likely to need the
>> attention of the 'glmulti' package's maintainer.
>>
>>
>> HTH,
>> Henric
>>
>>
>>
>>> But I have troubles to
>>> extract the exact information from this S4 class to make a simpler
>>> example because of my limited knowledge on S4 class. The author of the
>>> package is busy at the moment, and does not have time to look into it.
>>>
>>> Peng
>>>
>>> On 08/09/2012 10:25 PM, R. Michael Weylandt <[hidden email]>
>>> wrote:
>>>>
>>>> On Aug 9, 2012, at 9:14 PM, David Winsemius <[hidden email]>
>>>> wrote:
>>>>
>>>>> On Aug 9, 2012, at 4:56 PM, Zhang, Peng wrote:
>>>>>
>>>>>> Dear all,
>>>>>>
>>>>>> I had a R segmentation fault, and then invoked debug mode and ran
>>>>>> step
>>>>>> by step.
>>>>>
>>>>>> 2. Why does the same function behave differently under debug and
>>>>>> regular
>>>>>> mode?
>>>>> I cannot help you there.
>>>>>
>>>> Though a reproducible segfault is certainly worth a bug report if
>>>> you can do so, in debug or regular modes.
>>>>
>>>> You may wish to search stackoverflow for tips on how to make a great
>>>> reproducible example in R.
>>>>
>>>> Michael
>>> **********************************************************
>>> Electronic Mail is not secure, may not be read every day, and should
>>> not be used for urgent or sensitive issues
>>>
>>> ______________________________________________
>>> [hidden email] mailing list
>>> https://stat.ethz.ch/mailman/listinfo/r-help
>>> PLEASE do read the posting guide
>>> http://www.R-project.org/posting-guide.html
>>> and provide commented, minimal, self-contained, reproducible code.
>>>
>>
> **********************************************************
> Electronic Mail is not secure, may not be read every day, and should not be used for urgent or sensitive issues
>
>

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: debug vs regular mode

Zhang, Peng
Thanks! It is interesting that Windows has pointed the problem to Java.
So it is probable that how I did my debug led me to the wrong direction.

Since I was unsure how to debug S4 class, I copied the source implement
R function from glmulti package into my testing program.

The segmentation fault will appear when I step to "neotete =
terms(as.formula(paste("h~",paste(preds, collapse="*"))))". That is why
I have asked my initial question on the board.

The more interesting thing is that if I don't run library(glmulti), but
just the following lines, I won't have problem when I stepped to that
terms function.

I am totally lost. It is not clear to me how to debug S4 class.

Best,
Peng

### beginning
library(glmulti)

testdata = cbind(Y=rnorm(100), data.frame(matrix(rnorm(100*50), ncol = 50)))

glmulti =
function(y, xr, data, exclude, name, intercept, marginality , bunch,
chunk, chunks,
         level, minsize, maxsize, minK, maxK,
method,crit,confsetsize,popsize,mutrate,
         sexrate,imm, plotty,  report, deltaM, deltaB, conseq,
fitfunction, resumefile, includeobjects, ...) {
     if (missing(data))
         tete = terms(y)
     else
         tete = terms(y, data=data)
     oo = attr(tete,"order")
     dep = as.character(attr(tete,"variables"))[2]
     int = attr(tete,"intercept")
     preds = as.character(attr(tete,"variables"))[-(1:2)]
     if (level==2 && max(oo)>1) {
         # get all possible interactions
         interac = attr(tete,"term.labels")[oo==2]
         neotete = terms(as.formula(paste("h~",paste(preds, collapse="*"))))
         neointerac= attr(neotete,"term.labels")[attr(neotete,"order")==2]
         # get exclusions
         for (i in interac)
             neointerac=neointerac[neointerac!=i]
         # same for main effects
         mama = attr(tete,"term.labels")[oo==1]
         exma = preds
         for (j in mama)
             exma = exma[exma!=j]
         exma = c(exma,neointerac)
     } else {
         preds = attr(tete,"term.labels")[oo==1]
         exma=c(1)
     }
     call = match.call()
     call[[match("y", names(call))]] = dep
     call[[length(names(call))+1]] = preds
     names(call)[length(names(call))] ="xr"
         call[[length(names(call))+1]] = exma
     names(call)[length(names(call))] ="exclude"

     if (missing(data)) {
         call[[length(names(call))+1]] = environment(y)
         names(call)[length(names(call))] ="data"
     }
     eval(call)
}

debug(glmulti)

glmulti(Y~(X1+X2+X3+X4+X5+X6+X7+X8+X9+X10+X11+X12+X13+X14+X15)*X16,
xr=NULL, data = testdata, level = 2)
###end

On 08/10/2012 11:47 AM, Henric (Nilsson) Winell wrote:

> On 2012-08-10 15:42, Zhang, Peng wrote:
>
>> You are right. I am running Arch Linux. However, I obtained a
>> segmentation directly, so didn't know where to find the bug??
>>
>>   >  library("glmulti")
>> Loading required package: rJava
>>   > testdata = cbind(Y=rnorm(100), data.frame(matrix(rnorm(100*50), ncol
>> = 50)))
>>   > glmulti(Y~(X1+X2+X3+X4+X5+X6+X7+X8+X9+X10+X11+X12+X13+X14+X15)*X16,
>> data= testdata, level = 2)
>> Segmentation fault
>>
>> Is this information "Error in .jnew("glmulti/ModelGenerator", y,
>> jarray(xc), .jarray(xq),  : java.lang.ArrayIndexOutOfBoundsException:
>> 15" only in Windows, or did you see it under Fedora as well?
>
> Windows only.  Fedora just returned "Segmentation fault".
>
>
> //Henric
>
>
>
>>
>> Thank you!
>>
>> Peng
>>
>> BTW:
>>
>> $ uname -a
>> Linux Precision 3.4.7-1-ARCH #1 SMP PREEMPT Sun Jul 29 22:02:56 CEST
>> 2012 x86_64 GNU/Linux
>>
>>   > sessionInfo()
>> R version 2.15.1 (2012-06-22)
>> Platform: x86_64-unknown-linux-gnu (64-bit)
>>
>> locale:
>>    [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C
>>    [3] LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8
>>    [5] LC_MONETARY=en_US.UTF-8    LC_MESSAGES=en_US.UTF-8
>>    [7] LC_PAPER=C                 LC_NAME=C
>>    [9] LC_ADDRESS=C               LC_TELEPHONE=C
>> [11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C
>>
>> attached base packages:
>> [1] stats     graphics  grDevices utils     datasets  methods base
>>
>>
>> On 08/10/2012 09:25 AM, Henric (Nilsson) Winell wrote:
>>> On 2012-08-10 06:10, Zhang, Peng wrote:
>>>
>>>> Thanks to both for your reply.
>>>>
>>>> library(glmulti)
>>>> testdata = cbind(Y=rnorm(100), data.frame(matrix(rnorm(100*50), ncol
>>>> = 50)))
>>>> glmulti(Y~(X1+X2+X3+X4+X5+X6+X7+X8+X9+X10+X11+X12+X13+X14+X15)*X16,
>>>> data
>>>> = testdata, level = 2)
>>>>
>>>> This is reproducible to get a segmentation fault.
>>>
>>> There's some information missing here, notably the output from
>>> 'sessionInfo()', but I guess this is under GNU/Linux.  I can confirm a
>>> seg. fault under Fedora FC17 x86_64.
>>>
>>> Under Windows 7 64-bit, however, we get some further info:
>>>
>>>> library("glmulti")
>>> Loading required package: rJava
>>>> testdata = cbind(Y=rnorm(100), data.frame(matrix(rnorm(100*50), ncol
>>> = 50)))
>>>> glmulti(Y~(X1+X2+X3+X4+X5+X6+X7+X8+X9+X10+X11+X12+X13+X14+X15)*X16,
>>> data
>>> + = testdata, level = 2)
>>> Initialization...
>>> Error in .jnew("glmulti/ModelGenerator", y, .jarray(xc),
>>> .jarray(xq),  :
>>>    java.lang.ArrayIndexOutOfBoundsException: 15
>>>>
>>>> sessionInfo()
>>> R version 2.15.1 Patched (2012-08-06 r60178)
>>> Platform: x86_64-w64-mingw32/x64 (64-bit)
>>>
>>> locale:
>>> [1] LC_COLLATE=Swedish_Sweden.1252 LC_CTYPE=Swedish_Sweden.1252
>>> [3] LC_MONETARY=Swedish_Sweden.1252 LC_NUMERIC=C
>>> [5] LC_TIME=Swedish_Sweden.1252
>>>
>>> attached base packages:
>>> [1] stats     graphics  grDevices utils     datasets  methods base
>>>
>>> other attached packages:
>>> [1] glmulti_1.0.4 rJava_0.9-3
>>>>
>>>
>>> So, this doesn't seem to be a bug in R and is thus likely to need the
>>> attention of the 'glmulti' package's maintainer.
>>>
>>>
>>> HTH,
>>> Henric
>>>
>>>
>>>
>>>> But I have troubles to
>>>> extract the exact information from this S4 class to make a simpler
>>>> example because of my limited knowledge on S4 class. The author of the
>>>> package is busy at the moment, and does not have time to look into it.
>>>>
>>>> Peng
>>>>
>>>> On 08/09/2012 10:25 PM, R. Michael Weylandt
>>>> <[hidden email]>
>>>> wrote:
>>>>>
>>>>> On Aug 9, 2012, at 9:14 PM, David Winsemius <[hidden email]>
>>>>> wrote:
>>>>>
>>>>>> On Aug 9, 2012, at 4:56 PM, Zhang, Peng wrote:
>>>>>>
>>>>>>> Dear all,
>>>>>>>
>>>>>>> I had a R segmentation fault, and then invoked debug mode and ran
>>>>>>> step
>>>>>>> by step.
>>>>>>
>>>>>>> 2. Why does the same function behave differently under debug and
>>>>>>> regular
>>>>>>> mode?
>>>>>> I cannot help you there.
>>>>>>
>>>>> Though a reproducible segfault is certainly worth a bug report if
>>>>> you can do so, in debug or regular modes.
>>>>>
>>>>> You may wish to search stackoverflow for tips on how to make a great
>>>>> reproducible example in R.
>>>>>
>>>>> Michael
>>>> **********************************************************
>>>> Electronic Mail is not secure, may not be read every day, and should
>>>> not be used for urgent or sensitive issues
>>>>
>>>> ______________________________________________
>>>> [hidden email] mailing list
>>>> https://stat.ethz.ch/mailman/listinfo/r-help
>>>> PLEASE do read the posting guide
>>>> http://www.R-project.org/posting-guide.html
>>>> and provide commented, minimal, self-contained, reproducible code.
>>>>
>>>
>> **********************************************************
>> Electronic Mail is not secure, may not be read every day, and should
>> not be used for urgent or sensitive issues
>>
>>
>
**********************************************************
Electronic Mail is not secure, may not be read every day, and should not be used for urgent or sensitive issues

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: debug vs regular mode

Peter Dalgaard-2
Not to spoil your fun, but this is getting a bit off-topic for R-help. If you wish to continue the debugging process in public, I think you should move to R-devel.

Also, it sounds like the problem is in the glmulti package, so you might want to involve its maintainer at some point.

-pd

On Aug 10, 2012, at 19:51 , Zhang, Peng wrote:

> Thanks! It is interesting that Windows has pointed the problem to Java.
> So it is probable that how I did my debug led me to the wrong direction.
>
> Since I was unsure how to debug S4 class, I copied the source implement
> R function from glmulti package into my testing program.
>
> The segmentation fault will appear when I step to "neotete =
> terms(as.formula(paste("h~",paste(preds, collapse="*"))))". That is why
> I have asked my initial question on the board.
>
> The more interesting thing is that if I don't run library(glmulti), but
> just the following lines, I won't have problem when I stepped to that
> terms function.
>
> I am totally lost. It is not clear to me how to debug S4 class.
>
> Best,
> Peng
>
> ### beginning
> library(glmulti)
>
> testdata = cbind(Y=rnorm(100), data.frame(matrix(rnorm(100*50), ncol = 50)))
>
> glmulti =
> function(y, xr, data, exclude, name, intercept, marginality , bunch,
> chunk, chunks,
>         level, minsize, maxsize, minK, maxK,
> method,crit,confsetsize,popsize,mutrate,
>         sexrate,imm, plotty,  report, deltaM, deltaB, conseq,
> fitfunction, resumefile, includeobjects, ...) {
>     if (missing(data))
>         tete = terms(y)
>     else
>         tete = terms(y, data=data)
>     oo = attr(tete,"order")
>     dep = as.character(attr(tete,"variables"))[2]
>     int = attr(tete,"intercept")
>     preds = as.character(attr(tete,"variables"))[-(1:2)]
>     if (level==2 && max(oo)>1) {
>         # get all possible interactions
>         interac = attr(tete,"term.labels")[oo==2]
>         neotete = terms(as.formula(paste("h~",paste(preds, collapse="*"))))
>         neointerac= attr(neotete,"term.labels")[attr(neotete,"order")==2]
>         # get exclusions
>         for (i in interac)
>             neointerac=neointerac[neointerac!=i]
>         # same for main effects
>         mama = attr(tete,"term.labels")[oo==1]
>         exma = preds
>         for (j in mama)
>             exma = exma[exma!=j]
>         exma = c(exma,neointerac)
>     } else {
>         preds = attr(tete,"term.labels")[oo==1]
>         exma=c(1)
>     }
>     call = match.call()
>     call[[match("y", names(call))]] = dep
>     call[[length(names(call))+1]] = preds
>     names(call)[length(names(call))] ="xr"
>         call[[length(names(call))+1]] = exma
>     names(call)[length(names(call))] ="exclude"
>
>     if (missing(data)) {
>         call[[length(names(call))+1]] = environment(y)
>         names(call)[length(names(call))] ="data"
>     }
>     eval(call)
> }
>
> debug(glmulti)
>
> glmulti(Y~(X1+X2+X3+X4+X5+X6+X7+X8+X9+X10+X11+X12+X13+X14+X15)*X16,
> xr=NULL, data = testdata, level = 2)
> ###end
>
> On 08/10/2012 11:47 AM, Henric (Nilsson) Winell wrote:
>> On 2012-08-10 15:42, Zhang, Peng wrote:
>>
>>> You are right. I am running Arch Linux. However, I obtained a
>>> segmentation directly, so didn't know where to find the bug??
>>>
>>>> library("glmulti")
>>> Loading required package: rJava
>>>> testdata = cbind(Y=rnorm(100), data.frame(matrix(rnorm(100*50), ncol
>>> = 50)))
>>>> glmulti(Y~(X1+X2+X3+X4+X5+X6+X7+X8+X9+X10+X11+X12+X13+X14+X15)*X16,
>>> data= testdata, level = 2)
>>> Segmentation fault
>>>
>>> Is this information "Error in .jnew("glmulti/ModelGenerator", y,
>>> jarray(xc), .jarray(xq),  : java.lang.ArrayIndexOutOfBoundsException:
>>> 15" only in Windows, or did you see it under Fedora as well?
>>
>> Windows only.  Fedora just returned "Segmentation fault".
>>
>>
>> //Henric
>>
>>
>>
>>>
>>> Thank you!
>>>
>>> Peng
>>>
>>> BTW:
>>>
>>> $ uname -a
>>> Linux Precision 3.4.7-1-ARCH #1 SMP PREEMPT Sun Jul 29 22:02:56 CEST
>>> 2012 x86_64 GNU/Linux
>>>
>>>> sessionInfo()
>>> R version 2.15.1 (2012-06-22)
>>> Platform: x86_64-unknown-linux-gnu (64-bit)
>>>
>>> locale:
>>>   [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C
>>>   [3] LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8
>>>   [5] LC_MONETARY=en_US.UTF-8    LC_MESSAGES=en_US.UTF-8
>>>   [7] LC_PAPER=C                 LC_NAME=C
>>>   [9] LC_ADDRESS=C               LC_TELEPHONE=C
>>> [11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C
>>>
>>> attached base packages:
>>> [1] stats     graphics  grDevices utils     datasets  methods base
>>>
>>>
>>> On 08/10/2012 09:25 AM, Henric (Nilsson) Winell wrote:
>>>> On 2012-08-10 06:10, Zhang, Peng wrote:
>>>>
>>>>> Thanks to both for your reply.
>>>>>
>>>>> library(glmulti)
>>>>> testdata = cbind(Y=rnorm(100), data.frame(matrix(rnorm(100*50), ncol
>>>>> = 50)))
>>>>> glmulti(Y~(X1+X2+X3+X4+X5+X6+X7+X8+X9+X10+X11+X12+X13+X14+X15)*X16,
>>>>> data
>>>>> = testdata, level = 2)
>>>>>
>>>>> This is reproducible to get a segmentation fault.
>>>>
>>>> There's some information missing here, notably the output from
>>>> 'sessionInfo()', but I guess this is under GNU/Linux.  I can confirm a
>>>> seg. fault under Fedora FC17 x86_64.
>>>>
>>>> Under Windows 7 64-bit, however, we get some further info:
>>>>
>>>>> library("glmulti")
>>>> Loading required package: rJava
>>>>> testdata = cbind(Y=rnorm(100), data.frame(matrix(rnorm(100*50), ncol
>>>> = 50)))
>>>>> glmulti(Y~(X1+X2+X3+X4+X5+X6+X7+X8+X9+X10+X11+X12+X13+X14+X15)*X16,
>>>> data
>>>> + = testdata, level = 2)
>>>> Initialization...
>>>> Error in .jnew("glmulti/ModelGenerator", y, .jarray(xc),
>>>> .jarray(xq),  :
>>>>   java.lang.ArrayIndexOutOfBoundsException: 15
>>>>>
>>>>> sessionInfo()
>>>> R version 2.15.1 Patched (2012-08-06 r60178)
>>>> Platform: x86_64-w64-mingw32/x64 (64-bit)
>>>>
>>>> locale:
>>>> [1] LC_COLLATE=Swedish_Sweden.1252 LC_CTYPE=Swedish_Sweden.1252
>>>> [3] LC_MONETARY=Swedish_Sweden.1252 LC_NUMERIC=C
>>>> [5] LC_TIME=Swedish_Sweden.1252
>>>>
>>>> attached base packages:
>>>> [1] stats     graphics  grDevices utils     datasets  methods base
>>>>
>>>> other attached packages:
>>>> [1] glmulti_1.0.4 rJava_0.9-3
>>>>>
>>>>
>>>> So, this doesn't seem to be a bug in R and is thus likely to need the
>>>> attention of the 'glmulti' package's maintainer.
>>>>
>>>>
>>>> HTH,
>>>> Henric
>>>>
>>>>
>>>>
>>>>> But I have troubles to
>>>>> extract the exact information from this S4 class to make a simpler
>>>>> example because of my limited knowledge on S4 class. The author of the
>>>>> package is busy at the moment, and does not have time to look into it.
>>>>>
>>>>> Peng
>>>>>
>>>>> On 08/09/2012 10:25 PM, R. Michael Weylandt
>>>>> <[hidden email]>
>>>>> wrote:
>>>>>>
>>>>>> On Aug 9, 2012, at 9:14 PM, David Winsemius <[hidden email]>
>>>>>> wrote:
>>>>>>
>>>>>>> On Aug 9, 2012, at 4:56 PM, Zhang, Peng wrote:
>>>>>>>
>>>>>>>> Dear all,
>>>>>>>>
>>>>>>>> I had a R segmentation fault, and then invoked debug mode and ran
>>>>>>>> step
>>>>>>>> by step.
>>>>>>>
>>>>>>>> 2. Why does the same function behave differently under debug and
>>>>>>>> regular
>>>>>>>> mode?
>>>>>>> I cannot help you there.
>>>>>>>
>>>>>> Though a reproducible segfault is certainly worth a bug report if
>>>>>> you can do so, in debug or regular modes.
>>>>>>
>>>>>> You may wish to search stackoverflow for tips on how to make a great
>>>>>> reproducible example in R.
>>>>>>
>>>>>> Michael
>>>>> **********************************************************
>>>>> Electronic Mail is not secure, may not be read every day, and should
>>>>> not be used for urgent or sensitive issues
>>>>>
>>>>> ______________________________________________
>>>>> [hidden email] mailing list
>>>>> https://stat.ethz.ch/mailman/listinfo/r-help
>>>>> PLEASE do read the posting guide
>>>>> http://www.R-project.org/posting-guide.html
>>>>> and provide commented, minimal, self-contained, reproducible code.
>>>>>
>>>>
>>> **********************************************************
>>> Electronic Mail is not secure, may not be read every day, and should
>>> not be used for urgent or sensitive issues
>>>
>>>
>>
> **********************************************************
> Electronic Mail is not secure, may not be read every day, and should not be used for urgent or sensitive issues
>
> ______________________________________________
> [hidden email] mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.

--
Peter Dalgaard, Professor,
Center for Statistics, Copenhagen Business School
Solbjerg Plads 3, 2000 Frederiksberg, Denmark
Phone: (+45)38153501
Email: [hidden email]  Priv: [hidden email]

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: debug vs regular mode

Zhang, Peng
Ok. I will stop here. I have just created a bug report.

https://bugs.r-project.org/bugzilla3/show_bug.cgi?id=15013

If anyone is interested, please see if you can reproduce it.

Thanks,
Peng

On 08/10/2012 03:04 PM, peter dalgaard wrote:

> Not to spoil your fun, but this is getting a bit off-topic for R-help. If you wish to continue the debugging process in public, I think you should move to R-devel.
>
> Also, it sounds like the problem is in the glmulti package, so you might want to involve its maintainer at some point.
>
> -pd
>
> On Aug 10, 2012, at 19:51 , Zhang, Peng wrote:
>
>> Thanks! It is interesting that Windows has pointed the problem to Java.
>> So it is probable that how I did my debug led me to the wrong direction.
>>
>> Since I was unsure how to debug S4 class, I copied the source implement
>> R function from glmulti package into my testing program.
>>
>> The segmentation fault will appear when I step to "neotete =
>> terms(as.formula(paste("h~",paste(preds, collapse="*"))))". That is why
>> I have asked my initial question on the board.
>>
>> The more interesting thing is that if I don't run library(glmulti), but
>> just the following lines, I won't have problem when I stepped to that
>> terms function.
>>
>> I am totally lost. It is not clear to me how to debug S4 class.
>>
>> Best,
>> Peng
>>
>> ### beginning
>> library(glmulti)
>>
>> testdata = cbind(Y=rnorm(100), data.frame(matrix(rnorm(100*50), ncol = 50)))
>>
>> glmulti =
>> function(y, xr, data, exclude, name, intercept, marginality , bunch,
>> chunk, chunks,
>>          level, minsize, maxsize, minK, maxK,
>> method,crit,confsetsize,popsize,mutrate,
>>          sexrate,imm, plotty,  report, deltaM, deltaB, conseq,
>> fitfunction, resumefile, includeobjects, ...) {
>>      if (missing(data))
>>          tete = terms(y)
>>      else
>>          tete = terms(y, data=data)
>>      oo = attr(tete,"order")
>>      dep = as.character(attr(tete,"variables"))[2]
>>      int = attr(tete,"intercept")
>>      preds = as.character(attr(tete,"variables"))[-(1:2)]
>>      if (level==2 && max(oo)>1) {
>>          # get all possible interactions
>>          interac = attr(tete,"term.labels")[oo==2]
>>          neotete = terms(as.formula(paste("h~",paste(preds, collapse="*"))))
>>          neointerac= attr(neotete,"term.labels")[attr(neotete,"order")==2]
>>          # get exclusions
>>          for (i in interac)
>>              neointerac=neointerac[neointerac!=i]
>>          # same for main effects
>>          mama = attr(tete,"term.labels")[oo==1]
>>          exma = preds
>>          for (j in mama)
>>              exma = exma[exma!=j]
>>          exma = c(exma,neointerac)
>>      } else {
>>          preds = attr(tete,"term.labels")[oo==1]
>>          exma=c(1)
>>      }
>>      call = match.call()
>>      call[[match("y", names(call))]] = dep
>>      call[[length(names(call))+1]] = preds
>>      names(call)[length(names(call))] ="xr"
>>          call[[length(names(call))+1]] = exma
>>      names(call)[length(names(call))] ="exclude"
>>
>>      if (missing(data)) {
>>          call[[length(names(call))+1]] = environment(y)
>>          names(call)[length(names(call))] ="data"
>>      }
>>      eval(call)
>> }
>>
>> debug(glmulti)
>>
>> glmulti(Y~(X1+X2+X3+X4+X5+X6+X7+X8+X9+X10+X11+X12+X13+X14+X15)*X16,
>> xr=NULL, data = testdata, level = 2)
>> ###end
>>
>> On 08/10/2012 11:47 AM, Henric (Nilsson) Winell wrote:
>>> On 2012-08-10 15:42, Zhang, Peng wrote:
>>>
>>>> You are right. I am running Arch Linux. However, I obtained a
>>>> segmentation directly, so didn't know where to find the bug??
>>>>
>>>>> library("glmulti")
>>>> Loading required package: rJava
>>>>> testdata = cbind(Y=rnorm(100), data.frame(matrix(rnorm(100*50), ncol
>>>> = 50)))
>>>>> glmulti(Y~(X1+X2+X3+X4+X5+X6+X7+X8+X9+X10+X11+X12+X13+X14+X15)*X16,
>>>> data= testdata, level = 2)
>>>> Segmentation fault
>>>>
>>>> Is this information "Error in .jnew("glmulti/ModelGenerator", y,
>>>> jarray(xc), .jarray(xq),  : java.lang.ArrayIndexOutOfBoundsException:
>>>> 15" only in Windows, or did you see it under Fedora as well?
>>> Windows only.  Fedora just returned "Segmentation fault".
>>>
>>>
>>> //Henric
>>>
>>>
>>>
>>>> Thank you!
>>>>
>>>> Peng
>>>>
>>>> BTW:
>>>>
>>>> $ uname -a
>>>> Linux Precision 3.4.7-1-ARCH #1 SMP PREEMPT Sun Jul 29 22:02:56 CEST
>>>> 2012 x86_64 GNU/Linux
>>>>
>>>>> sessionInfo()
>>>> R version 2.15.1 (2012-06-22)
>>>> Platform: x86_64-unknown-linux-gnu (64-bit)
>>>>
>>>> locale:
>>>>    [1] LC_CTYPE=en_US.UTF-8       LC_NUMERIC=C
>>>>    [3] LC_TIME=en_US.UTF-8        LC_COLLATE=en_US.UTF-8
>>>>    [5] LC_MONETARY=en_US.UTF-8    LC_MESSAGES=en_US.UTF-8
>>>>    [7] LC_PAPER=C                 LC_NAME=C
>>>>    [9] LC_ADDRESS=C               LC_TELEPHONE=C
>>>> [11] LC_MEASUREMENT=en_US.UTF-8 LC_IDENTIFICATION=C
>>>>
>>>> attached base packages:
>>>> [1] stats     graphics  grDevices utils     datasets  methods base
>>>>
>>>>
>>>> On 08/10/2012 09:25 AM, Henric (Nilsson) Winell wrote:
>>>>> On 2012-08-10 06:10, Zhang, Peng wrote:
>>>>>
>>>>>> Thanks to both for your reply.
>>>>>>
>>>>>> library(glmulti)
>>>>>> testdata = cbind(Y=rnorm(100), data.frame(matrix(rnorm(100*50), ncol
>>>>>> = 50)))
>>>>>> glmulti(Y~(X1+X2+X3+X4+X5+X6+X7+X8+X9+X10+X11+X12+X13+X14+X15)*X16,
>>>>>> data
>>>>>> = testdata, level = 2)
>>>>>>
>>>>>> This is reproducible to get a segmentation fault.
>>>>> There's some information missing here, notably the output from
>>>>> 'sessionInfo()', but I guess this is under GNU/Linux.  I can confirm a
>>>>> seg. fault under Fedora FC17 x86_64.
>>>>>
>>>>> Under Windows 7 64-bit, however, we get some further info:
>>>>>
>>>>>> library("glmulti")
>>>>> Loading required package: rJava
>>>>>> testdata = cbind(Y=rnorm(100), data.frame(matrix(rnorm(100*50), ncol
>>>>> = 50)))
>>>>>> glmulti(Y~(X1+X2+X3+X4+X5+X6+X7+X8+X9+X10+X11+X12+X13+X14+X15)*X16,
>>>>> data
>>>>> + = testdata, level = 2)
>>>>> Initialization...
>>>>> Error in .jnew("glmulti/ModelGenerator", y, .jarray(xc),
>>>>> .jarray(xq),  :
>>>>>    java.lang.ArrayIndexOutOfBoundsException: 15
>>>>>> sessionInfo()
>>>>> R version 2.15.1 Patched (2012-08-06 r60178)
>>>>> Platform: x86_64-w64-mingw32/x64 (64-bit)
>>>>>
>>>>> locale:
>>>>> [1] LC_COLLATE=Swedish_Sweden.1252 LC_CTYPE=Swedish_Sweden.1252
>>>>> [3] LC_MONETARY=Swedish_Sweden.1252 LC_NUMERIC=C
>>>>> [5] LC_TIME=Swedish_Sweden.1252
>>>>>
>>>>> attached base packages:
>>>>> [1] stats     graphics  grDevices utils     datasets  methods base
>>>>>
>>>>> other attached packages:
>>>>> [1] glmulti_1.0.4 rJava_0.9-3
>>>>> So, this doesn't seem to be a bug in R and is thus likely to need the
>>>>> attention of the 'glmulti' package's maintainer.
>>>>>
>>>>>
>>>>> HTH,
>>>>> Henric
>>>>>
>>>>>
>>>>>
>>>>>> But I have troubles to
>>>>>> extract the exact information from this S4 class to make a simpler
>>>>>> example because of my limited knowledge on S4 class. The author of the
>>>>>> package is busy at the moment, and does not have time to look into it.
>>>>>>
>>>>>> Peng
>>>>>>
>>>>>> On 08/09/2012 10:25 PM, R. Michael Weylandt
>>>>>> <[hidden email]>
>>>>>> wrote:
>>>>>>> On Aug 9, 2012, at 9:14 PM, David Winsemius <[hidden email]>
>>>>>>> wrote:
>>>>>>>
>>>>>>>> On Aug 9, 2012, at 4:56 PM, Zhang, Peng wrote:
>>>>>>>>
>>>>>>>>> Dear all,
>>>>>>>>>
>>>>>>>>> I had a R segmentation fault, and then invoked debug mode and ran
>>>>>>>>> step
>>>>>>>>> by step.
>>>>>>>>> 2. Why does the same function behave differently under debug and
>>>>>>>>> regular
>>>>>>>>> mode?
>>>>>>>> I cannot help you there.
>>>>>>>>
>>>>>>> Though a reproducible segfault is certainly worth a bug report if
>>>>>>> you can do so, in debug or regular modes.
>>>>>>>
>>>>>>> You may wish to search stackoverflow for tips on how to make a great
>>>>>>> reproducible example in R.
>>>>>>>
>>>>>>> Michael
>>>>>> **********************************************************
>>>>>> Electronic Mail is not secure, may not be read every day, and should
>>>>>> not be used for urgent or sensitive issues
>>>>>>
>>>>>> ______________________________________________
>>>>>> [hidden email] mailing list
>>>>>> https://stat.ethz.ch/mailman/listinfo/r-help
>>>>>> PLEASE do read the posting guide
>>>>>> http://www.R-project.org/posting-guide.html
>>>>>> and provide commented, minimal, self-contained, reproducible code.
>>>>>>
>>>> **********************************************************
>>>> Electronic Mail is not secure, may not be read every day, and should
>>>> not be used for urgent or sensitive issues
>>>>
>>>>
>> **********************************************************
>> Electronic Mail is not secure, may not be read every day, and should not be used for urgent or sensitive issues
>>
>> ______________________________________________
>> [hidden email] mailing list
>> https://stat.ethz.ch/mailman/listinfo/r-help
>> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
>> and provide commented, minimal, self-contained, reproducible code.
**********************************************************
Electronic Mail is not secure, may not be read every day, and should not be used for urgent or sensitive issues

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: debug vs regular mode

Peter Dalgaard-2

On Aug 10, 2012, at 21:23 , Zhang, Peng wrote:

> Ok. I will stop here. I have just created a bug report.
>
> https://bugs.r-project.org/bugzilla3/show_bug.cgi?id=15013

...which is exactly what you should NOT do, if the bug is likely to live in a contributed package!!

-pd

>
> If anyone is interested, please see if you can reproduce it.
>
> Thanks,
> Peng
>
> On 08/10/2012 03:04 PM, peter dalgaard wrote:
>> Not to spoil your fun, but this is getting a bit off-topic for R-help. If you wish to continue the debugging process in public, I think you should move to R-devel.
>>
>> Also, it sounds like the problem is in the glmulti package, so you might want to involve its maintainer at some point.
>>
>> -pd

[much snipped]

--
Peter Dalgaard, Professor,
Center for Statistics, Copenhagen Business School
Solbjerg Plads 3, 2000 Frederiksberg, Denmark
Phone: (+45)38153501
Email: [hidden email]  Priv: [hidden email]

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Reply | Threaded
Open this post in threaded view
|  
Report Content as Inappropriate
star

Re: debug vs regular mode

Zhang, Peng
If you read my bug report, I just ran the same thing on both regular
mode and debug mode. That is why I think it is related with R base,
though there might be some other bugs related with glmulti or rJava.

Peng

On 08/10/2012 04:03 PM, peter dalgaard wrote:

> On Aug 10, 2012, at 21:23 , Zhang, Peng wrote:
>
>> Ok. I will stop here. I have just created a bug report.
>>
>> https://bugs.r-project.org/bugzilla3/show_bug.cgi?id=15013
> ...which is exactly what you should NOT do, if the bug is likely to live in a contributed package!!
>
> -pd
>
>> If anyone is interested, please see if you can reproduce it.
>>
>> Thanks,
>> Peng
>>
>> On 08/10/2012 03:04 PM, peter dalgaard wrote:
>>> Not to spoil your fun, but this is getting a bit off-topic for R-help. If you wish to continue the debugging process in public, I think you should move to R-devel.
>>>
>>> Also, it sounds like the problem is in the glmulti package, so you might want to involve its maintainer at some point.
>>>
>>> -pd
> [much snipped]
>
**********************************************************
Electronic Mail is not secure, may not be read every day, and should not be used for urgent or sensitive issues

______________________________________________
[hidden email] mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.
Loading...