Need help on using DRAM

24 views
Skip to first unread message

Saleh Rezaei

unread,
Feb 20, 2017, 1:30:33 PM2/20/17
to QUESO-users mailing list
Hello,

I have been trying to use Queso in order to solve an inverse problem by DRAM-MCMC algorithm. Before everything, I tried to play with the existing examples. 
In particular, let me focus on “hysteretic” in which Multilevel Sampling method (MLS) has been used to estimate 15 parameters. Imagine, we would like to run the case by DRAM, instead. By looking at the examples in the manual, specifically “bimodal”, I think we can edit the end part of “example_compute.C” as,

#if 1  //mcmc dram algorithm   
   QUESO::GslVector paramInitials(paramSpace.zeroVector());
   paramInitials[0] = 0.36;  // sigmaSquare
   for (unsigned int i=1; i<15 ;++i) {
       paramInitials[i]=0.0;   
   }

  QUESO::GslMatrix proposalCovMatrix(paramSpace.zeroVector());
   for (unsigned int i=0; i<15 ;++i) {
       proposalCovMatrix(i,i)=1.0;    
   }

ip.solveWithBayesMetropolisHastings(NULL,paramInitials,&proposalCovMatrix);

#else //multilevel sampling
   ip.solveWithBayesMLSampling();
#endif

without changing any other thing. If we compile and run the code with “mh” input file, we get this error: “application called MPI_Abort(MPI_COMM_WORLD, 1) - process 0”. According to the only existing file in the output directory, the last activity has been “Entering MetropolisHastingsSG<P_V,P_M>::commonConstructor()”. 
It seems “commonConstructor()” reads the input options, however, I could not find anything wrong in the input file. 
I checked this matter for a couple of other cases which had simpler model equations. The same thing was observed: with MLS everything is fine but DRAM fails. 
Considering several potential factors, it can be tested that if we avoid concatenating parameter domains (i.e. taking all parameters to be of the same type), both DRAM and MLS work well. 

I know that I might have made a mistake when using concatenated vectors/domains, but I cannot figure it out. It would be highly appreciated if you could help me on this matter. 

Best Regards, 
Saleh 

Damon McDougall

unread,
Feb 27, 2017, 3:58:08 PM2/27/17
to Saleh Rezaei, QUESO-users mailing list
Hi Saleh,

I totally forgot about your question. Sorry about that. I'll try to
see if I can recreate your error message and then I'll follow up with
you afterwards.
> --
> You received this message because you are subscribed to the Google Groups
> "QUESO-users mailing list" group.
> To unsubscribe from this group and stop receiving emails from it, send an
> email to queso-users...@googlegroups.com.
> Visit this group at https://groups.google.com/group/queso-users.
> For more options, visit https://groups.google.com/d/optout.


--
Damon McDougall
http://dmcdougall.co.uk
Institute for Computational Engineering Sciences
201 E. 24th St., Stop C0200
The University of Texas at Austin
Austin, TX 78712-1229

Damon McDougall

unread,
Feb 27, 2017, 6:08:37 PM2/27/17
to Saleh Rezaei, QUESO-users mailing list
Hi Saleh,

If you set

ip_mh_doLogitTransform = 0

in your input file, does the error go away? If so, this bug is already
known (see https://github.com/libqueso/queso/issues/472).

Let me know if this avoids the error for you.

Best wishes,
Damon

Saleh Rezaei

unread,
Mar 1, 2017, 8:06:27 AM3/1/17
to QUESO-users mailing list, saleh.r...@gmail.com
Hi Damon, 

Thank you so much for your support. 
I applied what you mentioned, but I could not remove the error. Now, this is what I receive:

Assertion `m_doLogitTransform == 1' failed.
m_doLogitTransform = 0
1 = 1
logit transform must be on to use logit_random_walk
stats/src/MetropolisHastingsSGOptions.C, line 640

Best Regards, 
Saleh

Damon McDougall

unread,
Mar 1, 2017, 9:20:39 AM3/1/17
to Saleh Rezaei, QUESO-users mailing list
Hi Saleh,

Sorry, the options changed recently, can you please also add:

ip_mh_tk = 'random_walk'

Best wishes,
Damon
> > > > email to queso-users...@googlegroups.com <javascript:>.
> > > > Visit this group at https://groups.google.com/group/queso-users.
> > > > For more options, visit https://groups.google.com/d/optout.
> > >
> > >
> > > --
> > > Damon McDougall
> > > http://dmcdougall.co.uk
> > > Institute for Computational Engineering Sciences
> > > 201 E. 24th St., Stop C0200
> > > The University of Texas at Austin
> > > Austin, TX 78712-1229
> > >
> > > --
> > > You received this message because you are subscribed to the Google
> > Groups
> > > "QUESO-users mailing list" group.
> > > To unsubscribe from this group and stop receiving emails from it, send
> > an
> > > email to queso-users...@googlegroups.com <javascript:>.

Saleh Rezaei

unread,
Mar 2, 2017, 5:51:28 AM3/2/17
to Damon McDougall, QUESO-users mailing list
​​Hi Damon, 

Thank you so much. If we add,

ip_mh_doLogitTransform = 0
ip_mh_tk = random_walk

to the input file, then we get a new error:

stats/src/MetropolisHastingsSGOptions.C, line 618,...
random_walk transition kernel and logit_random_walk algorithm are incompatible options

Then by adding, 

ip_mh_algorithm = random_walk

things work well!

I sincerely appreciate your assistance and support. 

Best Regards, 
Saleh





Damon McDougall

unread,
Mar 2, 2017, 8:31:16 AM3/2/17
to Saleh Rezaei, QUESO-users mailing list
Saleh,

Perhaps we ought to document those options a little better.  The fact I stumbled on them says a lot about how obvious they are.

In any case, that'll get you operating in the short term.  I'll work on fixing the core of the issue (I linked you to it in a previous email).

I'll also work on improving the documentation of our input file options.

Feel free to send another note if you have more questions. 

Best wishes,
Damon
> > > For more options, visit https://groups.google.com/d/optout.
> >
> >
> > --
> > Damon McDougall
> > Institute for Computational Engineering Sciences
> > 201 E. 24th St., Stop C0200
> > The University of Texas at Austin
> > Austin, TX 78712-1229
> >
>
> --
> You received this message because you are subscribed to the Google Groups
> "QUESO-users mailing list" group.
> To unsubscribe from this group and stop receiving emails from it, send an
Reply all
Reply to author
Forward
0 new messages