feat(soilgrids): support other/local soil data than SoilGrids (#105)#775
Open
michaelohanrahan wants to merge 1 commit into
Open
feat(soilgrids): support other/local soil data than SoilGrids (#105)#775michaelohanrahan wants to merge 1 commit into
michaelohanrahan wants to merge 1 commit into
Conversation
… metadata Generalize the soilgrids workflow beyond hardcoded SoilGrids 2017/2020 so any layered soil source works (e.g. 3-layer OpenLandMap, SLGA). Legacy soilgrids registry acts as fallback, but new sources can contain soil_depth_edges_cm in dataset attributes, and the averaging scheme of point/interval to remove stiff soil_fn=="soilgrids_2020" branching. For soil properties that are less than the column max depth assume homogeneous propertied from deepest available observation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Probably closes #105 but a separate issue is required for the discussion on vector soil setup report. #105 originally opened identifying the restrictions of using
soil_fn=="soilgrids_2020"branching to identify block or trapezoidal layer averaging of soil properties. This limited the flexibility in using non soilgrids datasources.Simultaneously closes #772, where some sources require an averaging to 2m where the information in the source doesnt exist and is filled to the max required depth.
Issue addressed
Fixes #105 and #772
Explanation
#105
** Resampling switch by parameter type ** - introduce an input dataset attribute
soil_layer_type: point or interval(accessible viads.attrs["soil_layer_type"]) to switch between trapezoidal or block averaging, respectively. Removingsoilgrids_2020branching, but for now retains fallback for legacy datasets that do not have the attribute.** Varying soil layer depths as input ** - ideally sources self-describe via dataset attribute
soil_depth_edges_cmcombined withsoil_layer_typeso any n-layer source should work (similarly with fallback for legacy datasets)#772
solving soil average dilution in the case that soil property layer limits <2m the soil property is assumed homogeneous from the last point of information to the base of the column. i.e. for a dataset with deepest property layer 60cm to 1m, the column to 2m is equal to the property values in that last layer.
Checklist
mainAdditional Notes (optional)
New issue required for #105 where vector support is identified moved to new issue #774