Reproducible Code and Data for Millet Yield Forecasting
This release provides the complete reproducible implementation, datasets, experimental configurations, and results associated with the study on deep temporal ensembles and hybrid stacking for millet yield forecasting in Senegal and cross-domain validation using calibrated synthetic crop-yield data from India.
Scope
The study develops an applied decision-support framework for the AgriFood value chain, with the objective of supporting early-season agricultural planning and food-security assessment.
The main Senegal dataset covers 2000–2020, 14 regions, and 294 zone–year observations. The experimental framework evaluates temporal deep-learning architectures and ensemble methods, including TimesNet, FEDformer, TimeMixer, XGBoost, and optimized hybrid stacking.
A post-hoc five-point data-leakage audit was conducted to identify target-derived features inadvertently available at the final prediction timestep. The audit reduced the initial ensemble performance from approximately R² = 0.83 to a corrected R² = 0.504. After leakage correction, XGBoost using legitimate flat tabular and lag-based features achieved R² = 0.821, demonstrating the strong predictive value of valid lag information and explaining why explicit temporal architectures may provide limited additional benefit for short sequences in this predominantly linear/autocorrelated setting.
For external validation, a calibrated synthetic multi-state India crop-yield dataset covering 32 states, 1995–2021, and 864 observations is included. The dataset was generated to reproduce relevant statistical properties and non-linear agronomic response structures derived from documented official agricultural statistics and survey information.
Under this controlled non-linear setting, the Optimized Hybrid Stacking model achieved R² = 0.743, compared with R² = 0.721 for XGBoost, corresponding to ΔR² = +0.022 (p = 0.037).
Main contributions represented in this release
A rigorous five-point data-leakage audit and correction procedure.
Leakage-free temporal validation and evaluation protocols.
Comparative evaluation of temporal deep-learning architectures and tree-based models.
Analysis of the performance reversal observed after leakage correction.
Identification of legitimate lag features as a dominant source of predictive information.
Optimized hybrid stacking with an MLP meta-learner.
Cross-domain validation using calibrated synthetic crop-yield data with controlled non-linear agronomic relationships.
Reproducible preprocessing, training, evaluation, and statistical comparison procedures.
Experimental results, figures, tables, and model predictions used in the study.
Optional blockchain-based provenance mechanisms for data-transparency and traceability experiments.
Reproducibility
The repository contains the source code, data-processing procedures, model implementations, experimental configurations, and generated outputs required to reproduce the reported experiments.
Users should follow the instructions provided in the repository README to:
Prepare the datasets.
Execute preprocessing and leakage-audit procedures.
Train the evaluated models.
Generate predictions and evaluation metrics.
Reproduce the statistical comparisons.
Generate the reported figures and tables.
Datasets
The release distinguishes between the Senegal observational dataset and the calibrated synthetic India dataset. The documentation specifies the origin, preprocessing, construction, and intended use of each dataset.
The synthetic India dataset is intended for methodological validation and controlled experimentation. It should not be interpreted as a direct replacement for independently collected observational agricultural data.
Version
Release: v1.0.0
Status: Reproducible research release
Scope: Code, datasets, experimental configurations, results, and documentation
This release corresponds to the version of the computational materials used for the reported experiments and is intended to provide a stable reference for citation and reproducibility.
Full Changelog:
github.com