Datasets:
You need to agree to share your contact information to access this dataset
This repository is publicly accessible, but you have to accept the conditions to access its files and content.
This dataset is in validation phase. Access is granted to verified researchers and organizations. Please describe your intended use case.
Log in or Sign Up to review the conditions and access this dataset content.
Soil Spectral Analysis Dataset
Synthetic soil spectral dataset for predicting nutrient content from reflectance data. I'm based in Austria and got interested in precision agriculture after talking to some farmers in Lower Austria who were paying a fortune for lab-based soil tests. The idea here was to create a training dataset that captures the relationship between what a spectrometer "sees" and what's actually in the soil — nitrogen, phosphorus, potassium, organic matter, pH.
The dataset covers 8 soil types common in Central Europe, with a focus on Austrian regions. The physics is simplified but the spectral shapes are realistic — darker soils have lower reflectance, organic matter creates an absorption feature around 1400nm, and the overall curve rises into the near-infrared like real soil spectra do. The nutrient values are correlated with soil type and organic matter content (e.g. nitrogen tracks organic matter via the Bremner relation, podzols are acidic, chernozems are nutrient-rich).
What's in it
- 4,000 samples across 8 soil types
- 24-band reflectance spectra from 350–1500nm (50nm steps)
- Soil chemistry: N, P, K, organic matter, pH
- Metadata: soil type, region, sampling depth, texture, land use, crop
Soil types
| Soil type | Count | Typical region | pH range | Notes |
|---|---|---|---|---|
| Chernozem | 800 | Weinviertel | 6.2–7.5 | Dark, fertile, high OM |
| Brown earth | 600 | Waldviertel | 5.5–6.8 | Mixed forest/ag soils |
| Rendzina | 500 | Alpine foothills | 7.0–8.2 | Shallow, calcareous |
| Alluvial | 500 | Danube valley | 6.5–7.8 | River-deposited, variable texture |
| Podzol | 400 | Alpine | 3.8–5.2 | Acidic, high OM, low P/K |
| Gleysol | 300 | Neusiedlersee | 5.0–7.0 | Waterlogged, clay-rich |
| Sandy | 400 | Marchfeld | 5.5–7.0 | Light, low OM, droughty |
| Loess | 500 | Lower Austria | 6.8–8.0 | Wind-deposited silt, vineyards |
Spectral physics
Each soil type has a characterisitc base reflectance curve shaped by:
- Albedo: sandy soils are bright (
0.18), podzols are dark (0.06) - Slope: reflectance generally increases with wavelength into NIR
- Organic matter absorption: dip near 1400nm from O-H and C-H bonds, stronger in high-OM soils
- Iron oxide absorption: subtle dip around 900nm
- NIR plateau: slight bump around 950nm typical of mineral soils
Individual samples vary through Gaussian noise, smooth sinusoidal perturbations, and parameter shifts tied to depth and organic matter content.
Usage
from datasets import load_dataset
ds = load_dataset("Laborator/soil-spectral-analysis")
# Get a sample
sample = ds["train"][0]
print(sample["soil_type"], sample["nitrogen_pct"])
# Quick scatter
import matplotlib.pyplot as plt
import numpy as np
fig, ax = plt.subplots()
for sample in ds["train"].select(range(100)):
ax.plot(sample["wavelengths_nm"], sample["reflectance"], alpha=0.3)
ax.set_xlabel("Wavelength (nm)")
ax.set_ylabel("Reflectance")
plt.show()
Files
data/soil_spectral.jsonl— one JSON object per linedata/soil_spectral.parquet— same data in Parquet format
Intended use
- Training regression models to predict soil nutrients from spectral data
- Benchmarking spectral feature extraction methods
- Teaching/demos for precision agriculture concepts
This is synthetic data — don't use it for actual agronomic decisions. Real soil spectra have more complexity (moisture variation, surface roughness, mixed pixels). But the spectral shapes and correlations should be good enough for model development and prototyping.
License
Apache 2.0
- Downloads last month
- 10