Scheduled Downtime
On Tuesday 24 October 2023 @ 5pm MT the forums will be in read only mode in preparation for the downtime. On Wednesday 25 October 2023 @ 5am MT, this website will be down for maintenance and expected to return online later in the morning.
Normal Operations
The forums are back online with normal operations. If you notice any issues or errors related to the forums, please reach out to help@ucar.edu

micro_mg_version = 2 runtime error

Hi there,I am attempting to run with MG2 in CAM (in cesm1.3_beta15).  When micro_mg_version = 1 (micro_mg_sub_version = 0) then CAM5 (and the rest of CESM) runs successfullyHowever, when I simply change micro_mg_version = 2, I get the following error (which is thrown in constituents.F90, subroutine cnst_add)advected tracer index greater than pcnst =           25Am I perhaps missing an additional namelist or other model initialization tweak, that will allow MG2 to run?Thanks in advance for any help, apologies if I missed something obvious here.Jeremy Fyke
 

eaton

CSEG and Liaisons
Setting the microphysics to MG2 must be done at build time (in order to get the number of constituents correctly specified).  So you need to give CAM's configure the argument "-microphys mg2".  That should be sufficient (I haven't tried it myself) to get the number of constituents right and to correctly set the namelist variables like "micro_mg_version". 
 
Hi again,After getting past the previous issue associated with running MG2 in a BG-compset simulation, I am now experiencing the following:When I try to start up a coupled CESM simulation (BG comp-set) with RUN_TYPE=‘startup' and set:    CAM_CONFIG_OPTS='-phys cam5 -microphys mg2’The executable attempts to locate one or more rpointer files (i.e. pointers to restart files).  It then dies with an error:     0:forrtl: No such file or directory     0:forrtl: severe (29): file not found, unit 98, file /glade/scratch/jfyke/BG_MG2_CISM2/run/rpointer.drvThe problem is, rpointer files (and staged restart files themselves) should not actually be required for a 'startup' coupled CESM simulation.  For reference, the coupled model does not attempt to locate non-existent and non-required rpointer files (and subsequently, runs successfully) if:    CAM_CONFIG_OPTS='-phys cam5’Perhaps implementation of MG2 does not include the ability to start from a non-restart-file data.. (i.e., requires a hybrid or branch run type)? or there is incomplete scripting at some point in the setup?  Or, most likely, I'm missing a step in the configure/build.Help much appreciated!Jeremy Fyke 505-709-0486
 

eaton

CSEG and Liaisons
Not sure what trouble you're running into with respect to restart files.  I just want to point out that mg2 can be run from initial files just as mg1 can.  An initial file produced by an mg2 run will contain 4 extra constituent fields (for prognostic precipitation), but those fields are not required for an initial run using mg2.  For example, if a run is configured to use mg2, but is started from an initial file that does not contain the prognostic precip fields, those constituents will just be initialized to zero.  Of course this doesn't apply to restarts.  You would not be able to restart a run configured for mg2 using restart files produced by a run configured with mg1. 
 

santos

Member
I cannot think of any way that the "-microphys mg2" option could cause this, and we do routinely test MG2 in CAM with no rpointer files present. You are sure that the run type is "startup" and CONTINUE_RUN is "FALSE"?
 
In digging into this it seems like when MG2 is specified (in a BG simulation), the scripts switch CONTINUE_RUN to TRUE in env_run.xml.  So I think that's the basic problem.I'm trying to track the reason for this switch down in the scripts.Jer 
 
Problem appears to be solved, sorry for the time spent.  I think the CONTINUE_Run setting was contaminated in some way to equal 'TRUE', from an earlier run I had carried out and then modified in the course of getting MG2 running.So: human (my) error.  I owe Brian Eaton and Sean Santos a beverage of their choice in Breckenridge.   
 
Top