PecanProject / pecan

The Predictive Ecosystem Analyzer (PEcAn) is an integrated ecological bioinformatics toolbox.
www.pecanproject.org
Other
202 stars 234 forks source link

ED2.2 on VM not running different PFTs #1261

Open ankurdesai opened 7 years ago

ankurdesai commented 7 years ago

It appears than an ecosystem model is not responding to user PFT selection in PECAN.

Description

A student running VM getting identical output when running ED2.2 with same site/climate but different PFTs (like temperate.early_hardhood vs. temperate.late_conifer). Meta-Analysis shows parameters are different (Vcmax 20 v 80 for example), but output of any variable like aboveground_biomass, NPP, NEE also are identical (or nearly).

Context

This suggests a bug in either web interface or model parameterization. Will update with specific run info shortly.

Possible Implementation

@istfer suggests an issue with PFT numbering in VM, so might be BETY based.

istfer commented 7 years ago

for example when I select temperate.Early_Hardwood from the VM web interface, the xml is like this:

    <pft>
      <name>temperate.Early_Hardwood</name> 
      <constants>
        <num>1</num>
      </constants>
    </pft>

I think this is what we want anyway but I think there is a bug in write.configs that this <num>1</num> has some sort of precedence over the PFT name, when I set it 9 for temperate.Early_Hardwood it runs with the correct params. so, I think this can be the problem with her runs too

robkooper commented 7 years ago

We had an issue about this in redmine, and have talked about this in gitter, thanks for opening this.

Since you can run with multiple PFT's the code will just start with num 1, next is 2, etc. Problem with this is that ED uses the pft numbers to set default values. We can solve this in two ways, associate with each pft for the ed model the corresponding pft number, PRO is easy, CON can not run with two PFTs that map to same number. Other option is to have for each PFT the default values needed in ED, and when creating the xml file, write out all default values as well.

I think in either case we might need a mapping from PFT to ED PFT number, so we might want to add to the pfts table in bety a field that allows us to add model specific information in xml format, and use that when creating the ED2IN file.

istfer commented 7 years ago

we already have a table for mapping, right? or do you have something else in mind @robkooper?

I'm also pinging @rykelly here because I think @mdietze and him had a similar discussion before and he has this comment in the code

ankurdesai commented 7 years ago

The big issue that concerns me is why are the posterior parameters from the MA not being passed to the model? Or if they are, not being used?

On Feb 23, 2017, at 2:09 PM, istfer notifications@github.com wrote:

we already have a table for mapping https://github.com/PecanProject/pecan/blob/master/models/ed/data/pftmapping.csv, right? or do you have something else in mind @robkooper https://github.com/robkooper?

I'm also pinging @rykelly https://github.com/rykelly here because I think @mdietze https://github.com/mdietze and him had a similar discussion before and has this comment https://github.com/PecanProject/pecan/blob/master/models/ed/R/write.configs.ed.R#L370-L378 in the code

— You are receiving this because you were assigned. Reply to this email directly, view it on GitHub https://github.com/PecanProject/pecan/issues/1261#issuecomment-282106404, or mute the thread https://github.com/notifications/unsubscribe-auth/AC8PlwRPaQI0Q1oM2FYUwIL8LhUG3Bnwks5rfeeUgaJpZM4MKUzD.

robkooper commented 7 years ago

@istfer yes that is a good mapping but I think it would be better to have it in BETY that way when you create a new PFT you can just add the mapping instead of having to modify the code.

@ankurdesai if they are passed, they should be passed in the config.xml file.

ankurdesai commented 7 years ago

Here are the VM runs my student did that got all the same output: Run ID Site Year Met Driver Model PFT 99000000011 Niwot Ridge Forest 2000-2005 ED-MET-DRIVER_HEADER 1998-2008 ED2 tempdecid 99000000013 Harvard Forest 2000-2005 ED-MET-DRIVER_HEADER 1998-2008 ED2 tempdecid 99000000014 Harvard Forest 2000-2005 ED-MET-DRIVER_HEADER 1998-2008 ED2 tempconif 99000000016 Niwot Ridge Forest 2000-2005 ED-MET-DRIVER_HEADER 1998-2008 ED2 tempconif.doe_vd 99000000017 Niwot Ridge Forest 2000-2005 ED-MET-DRIVER_HEADER 1998-2008 ED2 tempconif 99000000018 Niwot Ridge Forest 2000-2005 ED-MET-DRIVER_HEADER 1998-2008 ED2 tempdecid.doe_vd 99000000019 Harvard Forest 2000-2005 ED-MET-DRIVER_HEADER 1998-2008 ED2 tempdecid.doe_vd 99000000020 Niwot Ridge Forest 2000-2005 ED-MET-DRIVER_HEADER 1998-2008 ED2 temperate_Late_Hardwood 99000000021 Niwot Ridge Forest 2000-2005 ED-MET-DRIVER_HEADER 1998-2008 ED2 emperate.Early_Hardwood 99000000022 Niwot Ridge Forest 2000-2005 ED-MET-DRIVER_HEADER 1998-2008 ED2 temperate.Western_Hardwood 99000000024 Harvard Forest 2000-2005 ED-MET-DRIVER_HEADER 1998-2008 ED2 temperate_Late_Hardwood 99000000025 Harvard Forest 2000-2005 ED-MET-DRIVER_HEADER 1998-2008 ED2 emperate.Early_Hardwood 99000000026 Niwot Ridge Forest 2000-2005 ED-MET-DRIVER_HEADER 1998-2008 ED2  temperate.Early_Hardwood 99000000027 Niwot Ridge Forest 2000-2005 ED-MET-DRIVER_HEADER 1998-2008 ED2 temperate_Late_Hardwood 99000000029 Niwot Ridge Forest 2000-2005 ED-MET-DRIVER_HEADER 1998-2008 ED2 temperate_Mid_Conifer

All Harvard runs produced exactly this output:

99000000027 npp

I'll have her send me the config.xml files.

robkooper commented 7 years ago

did she pick any pss/css files? if not I think they always start with a bare ground run. My question is how different are the PFTs?

rykelly commented 7 years ago

What @robkooper said, for the most part. Great idea to move the mapping to BETY too...

ankurdesai commented 7 years ago

Thanks. I'll ask her. She did send me some config.xml files and they clearly show varying parameters, but probably bare ground.

github-actions[bot] commented 3 years ago

This issue is stale because it has been open 365 days with no activity.