pecan
pecan copied to clipboard
What function(s) should write config files to `settings$host$rundir`?
Bug Description
runModule.run.write.configs(settings)
appears to attempt to copy the files in settings$outdir
/run/ to settings$host$rundir
. This is currently failing for me (not sure why), but it doesn't seem to matter because runModule_start_model_runs()
also copies config files to settings$host$rundir
.
To Reproduce
My pecan.xml:
<?xml version="1.0"?>
<pecan>
<info>
<notes>Park Falls WLEF</notes>
</info>
<outdir>/data/output/pecan_runs/transect_runs/ed2_transect_WL</outdir>
<database>
<bety>
<driver>PostgreSQL</driver>
<user>bety</user>
<password>bety</password>
<host>postgres</host>
<dbname>bety</dbname>
<write>FALSE</write>
</bety>
<dbfiles>/data/dbfiles</dbfiles>
</database>
<pfts>
<pft>
<name>SetariaWT</name>
<ed2_pft_number>1</ed2_pft_number>
</pft>
<pft>
<name>temperate.Northern_Pine</name>
<ed2_pft_number>6</ed2_pft_number>
</pft>
<pft>
<name>temperate.Early_Hardwood</name>
<ed2_pft_number>9</ed2_pft_number>
</pft>
<pft>
<name>temperate.North_Mid_Hardwood</name>
<ed2_pft_number>10</ed2_pft_number>
</pft>
<pft>
<name>temperate.Late_Hardwood</name>
<ed2_pft_number>11</ed2_pft_number>
</pft>
</pfts>
<meta.analysis>
<iter>300</iter>
<random.effects>TRUE</random.effects>
<threshold>1.2</threshold>
<update>FALSE</update>
</meta.analysis>
<ensemble>
<size>50</size>
<variable>NPP</variable>
<samplingspace>
<parameters>
<method>lhc</method>
</parameters>
</samplingspace>
</ensemble>
<model>
<type>ED2</type>
<binary>/groups/dlebauer/ed2_results/global_inputs/ed2_2.2.0_singularity.sh</binary>
<id>14</id>
<edin>/pecan/models/ed/inst/ED2IN.r2.2.0</edin>
<config.header>
<radiation>
<lai_min>0.01</lai_min>
</radiation>
<ed_misc>
<output_month>12</output_month>
</ed_misc>
</config.header>
<phenol.scheme>0</phenol.scheme>
<ed2in_tags>
<PFT_1ST_CHECK>0</PFT_1ST_CHECK>
<IED_INIT_MODE>0</IED_INIT_MODE>
<MAXCOHORT>0</MAXCOHORT>
<MAXPATCH>0</MAXPATCH>
</ed2in_tags>
</model>
<run>
<site>
<id>678</id>
<met.start>2019-01-01 00:00:00</met.start>
<met.end>2019-12-31 23:59:59</met.end>
</site>
<inputs>
<met>/data/sites/MERRA_ED2_site_0-678/ED_MET_DRIVER_HEADER</met>
<veg>/data/oge2OLD/OGE2_</veg>
<soil>/data/faoOLD/FAO_</soil>
<lu>/data/ed_inputs/glu/</lu>
<thsum>/data/ed_inputs/</thsum>
</inputs>
<start.date>2019-01-01</start.date>
<end.date>2019-12-31</end.date>
</run>
<host>
<name>puma</name>
<folder>/groups/dlebauer/ed2_results/pecan_remote</folder>
<qsub>sbatch --job-name=@NAME@ --account=dlebauer --ntasks=28 --nodes=3 --time=25:00:00 -o @STDOUT@ -e @STDERR@</qsub>
<qsub.jobid>.* ([0-9]+)</qsub.jobid>
<qstat>'squeue --job @JOBID@ &> /dev/null || echo DONE'</qstat>
<prerun>module load openmpi3</prerun>
<modellauncher>
<binary>/groups/dlebauer/ed2_results/pecan/contrib/modellauncher/modellauncher</binary>
<qsub.extra>--partition=standard</qsub.extra>
<mpirun>module load openmpi3; mpirun</mpirun>
</modellauncher>
</host>
</pecan>
Expected behavior
It's not clear from the documentation which function is supposed to be doing this, but I'd think only one of them should. My vote is for the one that currently works for me 😆.