Request access to the Chactún multiclass detector

Requests are reviewed by hand. Access is for archaeological research, heritage management and related teaching.

This model finds candidate ancient Maya structures in airborne-lidar visualizations. Published with coordinates, its outputs could guide looting of undocumented sites. By requesting access you accept the LICENSE in this repository, including its use restrictions (Attachment A).

Log in or Sign Up to review the conditions and access this model content.

Chactún multiclass detector

Model summary

Instance segmentation of three classes of ancient Maya feature in airborne-lidar visualizations: building, platform and aguada (a water reservoir). The model is Detectron2 Mask R-CNN R50-FPN, initialized from COCO, trained with D4 augmentation (the eight symmetries of a square).

This checkpoint was trained on the ECML PKDD 2021 discovery challenge's training split (tiles 0–1764) and evaluated on its held-out split (tiles 1765–2093). It is arm D of the project's experiment matrix, seed 0, W&B run kmma010d.

Author: Benjamin J. Britton, University of Cincinnati.

Intended use

  • Archaeological research and heritage management.
  • Desktop survey: generating candidate features for review.
  • In every case, candidates are verified in the field by qualified archaeologists.

Out-of-scope and prohibited use

The LICENSE prohibits the following (Attachment A):

  • Publishing or sharing outputs with geographic coordinates, or in any form from which a location can be recovered.
  • Locating sites for unauthorized excavation, collection or trade.
  • Treating detections as confirmed archaeology without expert verification.

Also out of scope:

  • Imagery rendered differently from the input specification below, such as hillshade or other stretches.
  • Surveys coarser than about 1 m.

Training data

Chactún ML-ready dataset (Kokalj et al., Scientific Data 10:558, 2023; CC BY 4.0).

  • 2,094 tiles of 480 × 480 px at 0.5 m, covering 120.6 km² of the central Yucatán Peninsula.
  • Three bands: sky-view factor, positive openness, slope.
  • Labels are semantic masks, converted to instances for this model.
  • The 661 tiles with no annotation were kept in training as negatives.

Split used for this checkpoint. The challenge's canonical split: tiles 0–1764 for training, 1765–2093 (329 tiles) held out.

Cross-validation design. The figures below labelled five-fold CV come from five separate arm D models, one per fold, not from this checkpoint. Their folds are cluster-blocked: tiles are clustered by appearance and whole clusters are assigned to one side. The tiles carry no georeferencing, so a spatially blocked split is not possible.

Geomasking. The dataset authors withheld georeferencing deliberately, to protect undocumented sites from looting. This model and its outputs preserve that: inference_example.py reports pixel coordinates only.

Input specification

Three 8-bit bands, in this order. These are the general-terrain settings from Table 3 of Kokalj et al. 2023:

band visualization parameters stretch
1 sky-view factor 5 m radius, 16 directions linear 0.7–1.0
2 positive openness 5 m radius, 16 directions linear 68°–93°
3 slope — inverted, linear 0°–50°

Use 0.5 m resolution and 240 m × 240 m windows (480 px at 0.5 m). The model resizes each window to 800 px internally. preprocess_reference.md gives the formulas and how to tile other surveys by ground extent.

Warning. Apply the stretch function. Do not rescale your bands to match Chactún's mean and standard deviation. In the project's transfer test, matching band statistics gave a worse result than leaving the data unmodified.

Evaluation

Every figure below is segmentation AP unless marked otherwise, as recorded, with the split named. Sources are listed at the end of this section.

This checkpoint, canonical held-out split (329 tiles, single seed)

metric value
segm AP 44.63
segm AP50 / AP75 69.30 / 49.17
building / platform / aguada 42.39 / 55.25 / 36.24
bbox AP 42.33
semantic IoU, challenge convention (threshold 0.70) 0.7938

On the same split, the control without D4 (arm A) scores 40.46, which is 4.17 lower.

Five-fold CV (arm D fold models, not this checkpoint)

arm segm AP vs control 95% CI p AP50 AP75 building platform aguada
A, control 38.71 ± 2.45 — — — 62.05 40.32 39.36 48.69 28.08
D, D4 42.87 ± 2.80 +4.16 [+2.70, +5.61] 0.0014 65.15 46.21 44.27 53.46 30.88
  • The differences are paired by fold, and D is above A on every fold.
  • The interval is a t interval on 4 degrees of freedom.
  • The same difference on the canonical split is +4.17.

Operating points (five-fold CV, out-of-fold, not this checkpoint)

This table pools all 2,094 tiles (120.6 km²), with each structure scored once by the fold model that did not train on it. Use it to choose a score threshold against the cost of a field check. These figures were not measured for the released checkpoint itself.

score threshold recall false positives per km²
0.05 92.0% 188
0.10 89.9% 128
0.20 86.2% 81
0.50 75.0% 32
0.70 65.1% 16

Resolution sensitivity (five-fold CV, not this checkpoint)

Chactún tiles were resampled to simulate coarser surveys. The model input stays at 800 px, as with tiling by ground extent, and scoring is against the original annotations. The figures are arm D five-fold CV means:

survey resolution segm AP change from native aguada AP
0.5 m (native) 42.87 — 30.88
0.67 m 40.92 −5% 27.48
0.75 m 40.40 −6% 26.75
1.0 m 38.42 −10% 23.85
1.5 m 30.51 −29% 9.48
2.0 m 24.73 −42% 1.47

Aguada is the first class lost.

Semantic IoU against the challenge leaderboard (canonical split)

overall semantic IoU
this checkpoint (arm D) 0.7938
arm A control 0.7968
DeepLabV3-R50 semantic baseline, matched compute 0.8092
leaderboard 8th of 25 0.8110
leaderboard 1st 0.8341

The leading entries are five-fold ensembles with pseudo-labelling and test-time augmentation; this is a single model. Most of the gap to the semantic baseline comes from the instance-versus-semantic formulation (see Limitations). D4 raises instance AP by about 4 points but leaves semantic IoU level: 0.7938 against 0.7968 on a single seed per arm, which is no detectable difference.

Zero-shot comparison (canonical split, bbox AP)

model bbox AP
this checkpoint 42.33
Grounding DINO base, best of four prompt sets 3.08
OWLv2 base, best of four prompt sets 2.64

Both zero-shot models sit above a size-matched random-box null, so they are placing boxes on image content. They remain a factor of about fourteen below this model.

Sources

All files are in the project repository unless noted. The W&B project is benjbritton-geoai/chactun-multiclass.

  • Canonical split:
    • W&B run kmma010d, chactun-D-canonical-fold9-seed0.
    • Training metrics, iteration 3000: segm AP 44.625.
    • LAB_NOTEBOOK.md, entry "2026-09-03 - The canonical split, and an intervention that moves one metric but not the other".
  • Semantic IoU: LAB_NOTEBOOK.md, same entry, and the entry "2026-09-04 - The semantic baseline decomposes the leaderboard gap".
  • Five-fold CV:
    • W&B runs 6yyl1mzz, p4oat3vw, g1ezj9vy, wk28m8m8 and v35yrob5 (arm D, folds 0–4).
    • LAB_NOTEBOOK.md, entry "2026-09-01 - Milestone C: Chactun, and the first mechanism that worked".
    • The 95% CI, p and t come from the five per-fold paired differences against arm A runs plomgf53, 8e5dgv7h, af4zdqnw, v5ha72hv and 8wqkurnp.
  • Operating points: scripts/chactun_operating_point.py, run on the saved out-of-fold predictions.
  • Resolution sensitivity: scripts/chactun_scale_sensitivity.py, detail mode.
  • Zero-shot: posts/2026-09-17-open-vocabulary-detection-from-above.md.

Limitations

  • Aguada is weakly detected because the bands carry little signal for it.
    • These three bands emphasize raised features. An aguada is a depression, and it differs from background by about two counts where a building differs by 45–60.
    • The dataset authors traced aguada edges with a fourth visualization, local dominance, which the model does not receive.
    • More training data is unlikely to fix this; a different band might.
  • Validation optimism. Chactún tiles resemble one another so closely that every validation tile has a near-twin in training under any partition. On the canonical split, both arms score about 1.75 AP higher than under the appearance-clustered folds.
  • Usable resolution is roughly 0.33–1 m, with tiling by ground extent.
  • Accuracy on other surveys is unmeasured. The model was run on one different lidar survey, and its behaviour there is documented. That survey has no annotations, so precision and recall there are unknown.
  • Semantic IoU and instance AP measure different things.
    • Adjacent structures that touch fuse into one region under semantic masks, and the leaderboard scores those masks.
    • This model predicts separate instances, which semantic masks cannot. The cost on the leaderboard metric is 1.2–1.5 IoU points against a matched semantic baseline (0.8092 against 0.7968 for arm A and 0.7938 for arm D).
  • Single seed for the canonical-split figures. The CV figures carry intervals.
  • Statistical margin. A Bonferroni correction over the 35 tests run (five arms by seven metrics) sets a threshold of 0.00143, and the D4 result's p of 0.0014 clears it only narrowly. Its engineering evidence is stronger: it is positive on every fold and replicated on an external split.

How to use

Access is gated. Once approved:

pip install torch torchvision rasterio huggingface_hub
pip install 'git+https://github.com/facebookresearch/detectron2.git'
hf auth login
hf download benjbritton/chactun-multiclass-detector --local-dir chactun-detector
cd chactun-detector
python inference_example.py --image your_tile.tif --score 0.50

Output, here for Chactún tile 1767 (canonical test split), is in pixel coordinates of the tile only:

28 detections at score >= 0.50 (pixel coordinates, origin top-left)
class      score       x0       y0       x1       y1
aguada     0.969    226.6     18.5    348.4    170.2
building   0.966     16.5     53.2     40.0     86.1
platform   0.966     72.2    422.4    156.1    479.9
...

At score 0.05 the same tile gives 56 detections. Their classes, boxes and scores match the recorded evaluation of this checkpoint to print precision.

From Python:

from inference_example import load_tile, build_model, predict
cfg, model = build_model("config.yaml", "model_final.pth", "cuda")
inst = predict(cfg, model, load_tile("your_tile.tif"), score=0.50)

Prepare tiles as described in preprocess_reference.md.

Ethics and heritage protection

Publishing precise coordinates for thousands of undocumented Maya structures is a looting risk, and withholding georeferencing is standard practice for unexcavated sites. A detector that finds structures in lidar would carry the same risk if its outputs carried coordinates. For that reason:

  • The Chactún authors withheld georeferencing from the dataset.
  • Access to this model is gated with manual review, and every requester agrees not to publish located outputs.
  • inference_example.py never reads or writes a geotransform or CRS.
  • Pass-through use restrictions (LICENSE, Attachment A) carry the same terms to derivatives.

Licensing history. From its release on 2026-09-15 until 2026-10-17, this model was public and ungated under CC BY 4.0. Copies downloaded in that period remain under CC BY 4.0. Gating and the current license apply only to later downloads.

Enforceability. Whether use terms can bind weights trained on CC BY 4.0 data is an unsettled legal question. The restrictions are stated as the terms on which the model is offered. Gating and review are the practical safeguard.

The Chactún dataset remains available to anyone under CC BY 4.0 from its authors; this license does not restrict it.

Citation

This model:

@misc{britton2026chactun,
  author       = {Britton, Benjamin J.},
  title        = {Chact{\'u}n multiclass detector: Mask R-CNN for ancient Maya features in airborne lidar},
  year         = {2026},
  publisher    = {Hugging Face},
  howpublished = {\url{https://huggingface.co/benjbritton/chactun-multiclass-detector}}
}

Training data:

Kokalj, Ž., Džeroski, S., Šprajc, I., Štajdohar, J., Draksler, A., & Somrak, M. (2023). Machine learning-ready remote sensing data for Maya archaeology. Scientific Data, 10, 558. https://doi.org/10.1038/s41597-023-02455-x

Challenge:

Kocev, D., Simidjievski, N., Kostovska, A., Dimitrovski, I., & Kokalj, Ž. (2022). Discover the Mysteries of the Maya: Selected Contributions from the Machine Learning Challenge & The Discovery Challenge Workshop at ECML PKDD 2021. arXiv:2208.03163. https://arxiv.org/abs/2208.03163

Links

Files

file
model_final.pth Detectron2 checkpoint, 351 MB, SHA-256 0829cf49…eecd9416
config.yaml Full, self-contained Detectron2 config
inference_example.py Loads the model, runs one tile, prints class, score and pixel box
preprocess_reference.md Band recipe and tiling by ground extent
LICENSE Responsible-use license with Chactún CC BY 4.0 attribution
Downloads last month
-
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support

Paper for benjbritton/chactun-multiclass-detector