Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature VegArrays #136

Merged
merged 8 commits into from
Jan 23, 2018
Merged

Feature VegArrays #136

merged 8 commits into from
Jan 23, 2018

Conversation

dschlaep
Copy link
Member

@dschlaep dschlaep commented Jan 23, 2018

- start addressing #135

- all complete except those defined in SW_VegProd.h
- address #135

- convert vegetation variables defined in SW_VegProd.h
- 'key2veg' contains string representations of vegetation types
--> use for console message output
- address #135

- convert local vegetation variables defined in SW_Flow.c and SW_Site.c

- use pre-defined loop 'ForEachVegType' whenever possible
- define loop 'ForEachVegTypeBottomUp' for use by, e.g., hydraulic
redistribution

- SW_Flow_lib: collapsed all (identical) functions
* 'XXX_intercepted_water' into 'veg_intercepted_water'
* 'XXX_EsT_partitioning' into 'EsT_partitioning'
- this commit exactly reproduces output as current master (plus new fix
for forbs #47)
@codecov-io
Copy link

codecov-io commented Jan 23, 2018

Codecov Report

Merging #136 into master will decrease coverage by 1.21%.
The diff coverage is 62.15%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #136      +/-   ##
==========================================
- Coverage   34.12%   32.91%   -1.22%     
==========================================
  Files          20       20              
  Lines        3528     3151     -377     
==========================================
- Hits         1204     1037     -167     
+ Misses       2324     2114     -210
Impacted Files Coverage Δ
SW_Output_mock.c 2.96% <0%> (ø) ⬆️
SW_Flow_lib.c 0% <0%> (ø) ⬆️
SW_VegEstab.c 6.11% <0%> (-0.07%) ⬇️
SW_Flow.c 13.72% <14.84%> (+7.05%) ⬆️
SW_Site.c 64.62% <66.66%> (-1.6%) ⬇️
SW_Carbon.c 76.71% <87.5%> (-0.92%) ⬇️
SW_VegProd.c 67.46% <95.38%> (-3.37%) ⬇️

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update f49c5b6...c0448dc. Read the comment docs.

@dschlaep
Copy link
Member Author

@CaitlinA @BrendenBe1 This is a major code change:

  • note that vegetation type related variables are now arrays
  • use pre-defined macros to loop across vegetation types
    • normal use case: ForEachVegType
    • ForEachVegTypeBottomUp

This will make it easier for Brendan to get the vegetation cover values for the new SWA code.

@dschlaep dschlaep merged commit e5367b0 into master Jan 23, 2018
@dschlaep dschlaep deleted the feature_VegArrays branch January 23, 2018 20:32
@BrendenBe1
Copy link
Contributor

I am merging master into my branch now and will make implement this change into the SWA code

@BrendenBe1
Copy link
Contributor

@dschlaep I merged master into my branch and also changed my STEPWAT branch to work with the new veg arrays.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Convert vegetation type related variables to arrays
3 participants