Skip to content

techmatters/soil-id-algorithm

Repository files navigation

Soil ID Algorithm

explanation of algorithm

terminology

  • soil map unit: (possibly disjoint) geographic area that is associated with soil component percentage / arial coverage
  • soil series: collection of related soil components
  • soil component: description of various soil properties at specific depth intervals

references

dependencies

algorithm

Input: a specific point in lat/lon, and a set of depth intervals.

  1. Query for all map units within 1km of the point.
  2. Fall back to STATSGO at 10km if SSURGO is incomplete, or else declare not available if area not surveyed.
  3. Associate each map unit with its polygons' minimum distance to the point in question.
  4. Infill missing components by rescaling them to sum to 100.
  5. Calculate the component probabilities by, for each component, dividing the distance-weighted sum of that component's probability in each map unit by the total distance-weighted sum of each component's probability in each map unit.
  6. Limit to components in the top 12 component series by probability.
  7. Query the local database for the component horizons.
  8. Return the individual probabilities of data at each horizon based on the weighted sum of each component's data at each horizon.

Resources

SoilID Project Box Folder

• This folder contains the data schema and processed soil database tables that are ingested into the mySQL database.

https://nrcs.app.box.com/s/vs999nq9ruyetb9b4l7okmssdggh8okn

SSURGO/STATSGO2 metadata:

https://www.nrcs.usda.gov/resources/data-and-reports/ssurgo/stats2go-metadata

SSURGO/STATSGO data:

https://nrcs.app.box.com/v/soils/folder/17971946225

Testing

Regular tests

There is a small suite of integration tests which can be run with the make test command, and gets run regularly by CI.

Bulk test

There is a large suite of integration tests which takes many hours to run. It comes in the format of two scripts:

  • Run make generate_bulk_test_results to run the algorithm over a collection of 3000 soil pits, which will accumulate the results in a log file.
  • Run RESULTS_FILE=$RESULTS_FILE make process_bulk_test_results to view statistics calculated over that log file.

Acknowledgements

About

No description, website, or topics provided.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 4

  •  
  •  
  •  
  •  

Languages