# A region-wide, multi-year set of crop field boundary labels for Africa This repository hosts the analytical code and pointers to datasets resulting from a project to generate a continent-wide set of crop field labels for Africa covering the years 2017-2023. The data are intended for training and assessing machine learning models that can be used to map agricultural fields over large areas and multiple years. The project was funded by the [Lacuna Fund](https://lacunafund.org/), and led by [Farmerline](https://farmerline.co/), in collaboration with [Spatial Collective](https://spatialcollective.com/) and the [Agricultural Impacts Research Group](agroimpacts.info) at [Clark University](https://www.clarku.edu/departments/geography/). Please refer to the [paper](docs/manuscript/manuscript.pdf) for more details on the methods used to develop the dataset, an analysis of label quality, and usage guidelines. The paper and additional documents, analyses, and demonstration code used to develop labels can be obtained by cloning the repository: ``` bash git clone git@github.com:agroimpacts/lacunalabels.git cd lacunalabels pip install -e . ``` Please see the next sections for details on accessing the imagery and label data. ## Access and usage The imagery and labels can be obtained either from [Zenodo](https://zenodo.org/records/11060871) or the [Registry of Open Data on AWS](https://registry.opendata.aws/), and may used in accordance with Planet’s [participant license agreement for the NICFI contract](https://assets.planet.com/docs/Planet_ParticipantLicenseAgreement_NICFI.pdf). The code used to annotate and analyze the data is available under an [Apache 2.0 license](https://www.apache.org/licenses/LICENSE-2.0). ### Data on AWS The data are in the bucket `s3://africa-field-boundary-labels` in the `us-west-2` region, and are organized as follows:
| Prefix/key | Description |
|---|---|
| imagery/ | Contains 4 band Planet image chips in geotiff format, named as follows: XX1234567890_YYYY-MM.tif Representing a grid identifier and the image acquisition date and month |
| labels/ | A set of 3-class labels in geotiff format, named as: XX1234567890_123456_YYYY-MM.tif Representing a grid identifier, a labelling assignment identifier, and month and year of imagery being labelled. These labels represent one possible set from a larger number of labelling assignments, which were created using the demonstration notebook provided in this repository. |
| label-catalog-filtered.csv | Details of each labeling assignment for the subset developed using the demonstration notebook, including information on label quality. |
| mapped_fields_final.parquet | The original digitized field boundaries collected on the Planet imagery, in geoparquet format. These can be used together with the image chips, the code provided in the demonstration notebook, the full labelling assignment (label_catalog_allclasses.csv) and the image chip catalog (image_chip_catalog.csv) to make different subsets of labels. |