Skip to content
TerraTraceTerraTrace Open LiDAR · DTM

Guides / MethodFrom point cloud to candidate

How TerraTrace
finds earthworks.

TerraTrace screens airborne laser scanning data for the relief of strongholds and other earthworks and hands an archaeologist a ranked list of places to look at. This page describes each step, what the detector was trained on, how its accuracy was measured and where it falls short.

In one sentence: it proposes candidates. It does not decide what is a site. That stays with the person reviewing them.

Updated
11 October 2026
Reading time
10 min
On this page07
  1. 01From an area to a list of candidates
  2. 02Review by an archaeologist
  3. 03What the detector learned from
  4. 04How accuracy was measured
  5. 05Limits of the method
  6. 06What it mistakes for earthworks
  7. 07What this means for your work

From an area to a list of candidates

A scan starts with a rectangle on the map, between 0.5 and 20 km on a side. The rest runs on its own.

  1. Finding the data. TerraTrace works out which open LiDAR source covers the rectangle and fetches all of it. In Poland it asks the national geoportal (GUGiK) which laser scanning sheets cover the rectangle and downloads every one of them; where a sheet was flown more than once, it takes the most recent survey. How the sheets and survey years work is explained in the guide to LiDAR data on Geoportal. In the other countries it reads the data of the national or regional mapping agency in 1 km pieces.
  2. Keeping only the ground. A point cloud records treetops and roofs as well as the ground. Only the points classified as ground are kept. From them TerraTrace builds a terrain model on a 0.5 m grid, lightly smoothed. Where the nearest ground point is more than 10 m away (open water, a large roof) the cell is left blank instead of being invented. Where an agency publishes a finished terrain model rather than a point cloud (in the United States, for example), that model is used instead.
  3. Lighting the terrain. The terrain model is shaded as if lit by a low sun, 25° above the horizon, from five directions: 315°, 45°, 135°, 225° and 337.5°. Height differences are exaggerated so that even a low bank casts a visible shadow. Each shaded image is blended with a slope image and its local contrast is evened out, so that a faint rampart in flat fields and one on a steep hillside are both readable. Why one direction is not enough is shown in how to read LiDAR for archaeology.
  4. Cutting into tiles. Each shaded image is cut into tiles of 1024 × 1024 pixels, that is 512 × 512 m of ground, overlapping by 25 m so that a site on a tile boundary appears whole in at least one of them.
  5. Detecting. A trained detector looks at every tile under every light direction and draws a box around anything that resembles an earthwork, with a confidence between 0 and 1. Boxes from different light directions that cover the same spot are merged into one candidate. Each candidate records its confidence and in how many of the five images it was seen.
  6. Placing on the map. Pixel boxes are converted to map coordinates. For a Polish scan that is the national grid EPSG:2180, the system used by Geoportal and by most Polish heritage records. Elsewhere the terrain images stay in the data's own national grid, and every candidate also carries WGS84 coordinates.

The terrain model and the shaded images are kept with the scan, so the reviewer looks at exactly what the detector looked at.

Review by an archaeologist

Candidates are listed from the most to the least confident. Clicking one shows it on the shaded relief, with a switch between the five light directions, its coordinates and a link to the same place in the national map viewer (Geoportal in Poland). The reviewer marks each candidate as real, false or unsure. A confidence slider hides the weaker ones; boxes that nearly coincide, because neighbouring tiles overlap, can be hidden as duplicates.

Fig. 1TerraTrace scan, 08.10.2026 · Źródło danych: GUGiK · map tiles © OpenStreetMap contributors

The TerraTrace review screen: a list of seven candidates on the left, shaded relief of the Czermno stronghold with candidate boxes on the right
Review of a real scan around the stronghold at Czermno (gm. Tyszowce), a registered monument that was not among the training sites. Candidate no. 1 sits on the rampart with confidence 0.89 and was seen under all five light directions. Lower-ranked candidates are listed below it for the reviewer to accept or reject.

A finished review can be downloaded as a package that opens directly in QGIS: a shaded mosaic of the whole area for each light direction and the terrain model as GeoTIFFs, and the candidates as GeoJSON with a ready style, GeoPackage, KML, GPX and CSV, all georeferenced (in EPSG:2180 for a Polish scan). Each candidate carries its confidence, the light directions that showed it and the reviewer's verdict.

What the detector learned from

The detector is an object detector of the YOLO family, trained for a single class: earthwork. It learned from shaded images made with the same lighting and contrast steps as a scan, from the same 0.5 m terrain models. One difference remains: the training images were drawn at a slightly finer scale, about 0.4 m per pixel against 0.5 m in a scan.

  • 217 areas in total. 170 of them contain at least one earthwork outlined by hand, mostly known strongholds (313 boxes drawn in all). 47 contain none and are there on purpose, so the detector also learns what to leave alone.
  • The areas without earthworks include natural hills, flat ground and woodland, and 24 places from real scans where an earlier version of the detector had boxed something that, on review, was not an earthwork.
  • Each training image was rendered under the same five light directions used in a scan, and images are rotated and flipped at random during training, so the orientation of a site and the direction of the light do not matter to it.
  • The outlined earthworks range from about 25 m to about 350 m across, typically around 90 m.

How accuracy was measured

The usual mistake in this kind of work is to cut the data into tiles first and split the tiles at random. Neighbouring tiles of the same site then end up on both sides, and the test only checks whether the model remembers a place it has already seen. TerraTrace splits by area: all tiles of one site are either in training or in testing, never both.

Testing used five-fold cross-validation. The 217 areas were divided into five groups of 43 or 44. Five separate models were trained, each on four groups, and each was scored on the fifth group, which it had never seen. Every area was a test area exactly once.

Scores of the current detector on held-out areas, one row per fold. ± is the standard deviation across the five folds.
FoldmAP50mAP50-95
10.5950.356
20.7540.418
30.6560.413
40.7290.395
50.6950.386
Average0.686 (± 0.056)0.394

What mAP50 means in plain words

A detected box counts as a hit when it overlaps a hand-drawn outline by at least half (50 % intersection over union, hence the 50). Walk down the detector's boxes from the most to the least confident: precision is the share of boxes so far that are hits, recall the share of outlined earthworks found so far. mAP50 sums up that curve in one number. 1.0 would mean every earthwork found and ranked above every false alarm.

0.686 means the detector finds most outlined earthworks and ranks them mostly above the false alarms, but not all of them and not always. It is not the share of sites found, and it says nothing about places nobody has outlined yet. The stricter mAP50-95 mostly reflects how tightly the box fits the outline, which matters less for review than whether the place is flagged at all.

The spread between folds, from 0.595 to 0.754, is as informative as the average. The score depends on which sites fall in the test group: some earthworks are clear, others faint, cut by roads or under dense forest. Expect results on a new area to vary in the same way.

What the extra light directions added

An earlier detector of the same type, trained for the same length on images lit from one direction only, averaged 0.631 mAP50 in the same five-fold test. Training on all five directions brought the average to 0.686, about 5 percentage points more. The comparison is not perfectly clean: the newer run also included the 24 false-alarm places, and its test images were lit from all five directions too. The gain belongs to these changes together.

Limits of the method

  • Sites with no relief left. LiDAR records shape, not soil. A rampart ploughed flat, a site known only from finds or crop marks, or one built over leaves nothing for the detector to see.
  • Small features. The smallest earthwork in training was about 25 m across. Single barrows, small pits and other features much smaller than that are not what it was trained for.
  • Sheet edges and gaps. Each survey sheet is processed on its own, so a site cut by a sheet boundary is seen in two halves, each less recognisable. Blank patches (water, large buildings) and places where few laser pulses reached the ground under dense cover give a poor terrain model.
  • Places without data. In Poland TerraTrace currently uses the 2011–2019 national survey series, the one the detector was trained on. Where that series has no sheet, there is nothing to scan. Newer, denser surveys exist for parts of the country; they will be used once the detector has been tested on them. You can check Polish coverage of any area with the free LiDAR sheet finder. Elsewhere TerraTrace uses what each agency publishes, and in some countries that covers only part of the territory.
  • Other kinds of earthwork, other landscapes. The training set is mostly Polish strongholds. Earthworks of a different kind were not specifically taught, so do not rely on the detector alone for them. Outside Poland results depend on the type of monument, and a pilot on an area with known sites shows what a scan gives you there.

What it mistakes for earthworks

The detector responds to shape: a closed or curved bank, a ring, a raised platform with a ditch. Anything modern or natural with that shape can be boxed. In real scans we have seen it flag round industrial structures, groups of embanked basins, curved banks and gullies at woodland and field edges, and hummocky natural ground. Places like these were fed back into training as examples of what is not an earthwork. The detector still boxes such places at times, so expect some in every scan.

Most are easy to dismiss with a glance at an orthophoto or topographic map, which is why each candidate links to the national map viewer. The detector is tuned to report too much rather than too little: a false alarm costs a reviewer a few seconds, a missed site may cost far more.

What this means for your work

Treat the output as a desk-based screening layer. It is a systematic first pass over the whole area under the same rules. It does not replace the monuments register, archive queries or a site visit, and a candidate is not a site until someone with the right expertise says so. Fieldwork on any candidate needs the permits that apply where it lies; in Poland, a permit from the voivodeship heritage conservator.

To see the detector on known strongholds, with real detections, read TerraTrace in action. For use in planning and environmental assessment, see the pre-development assessment guide. How scans are priced is on the pricing page.

Rather not do it by hand?

TerraTrace fetches the open LiDAR for your area, builds the bare-earth model, lights it from five directions and ranks the earthwork candidates for your review.

Ask for a pilot