01

Scanning books

Libraries and archives scan millions of books to preserve them and make them available online. When a book is photographed open, the two pages form a spread, joined at the gutter, the inner margin where the pages meet at the binding. Software often needs to locate the gutter to split the spread into separate pages and correct curvature.

02

Shadows in the gutter

In a tightly bound book that cannot open flat, the pages curve down into the gutter, creating a deep, dark shadow. A model trained on such books might learn that the gutter is simply the darkest vertical band in the image. This works for many books, but not all.

03

Books that lie flat

Some books, such as those with lay-flat bindings or spiral bindings, open almost completely flat. Their gutters show little or no shadow. A model relying on darkness could miss the gutter entirely, or mistake another dark feature, such as an illustration or a dark page edge, for the junction.

04

Label the junction

To avoid teaching the model a shortcut, labels should mark the actual junction where the pages meet, not the centre of the shadow. In many books the two are close together, but when light comes from one side, the shadow shifts to one side of the junction.

05

Moving the light

A useful control test photographs the same open spread twice, once lit from the left and once from the right, without moving the book or camera. The junction stays in the same place, but the shadow moves. If the model's predicted gutter moves with the shadow, it is following darkness rather than the junction.

06

Unseen books and angles

The test set should also include books that were not used in training, with different bindings, paper colours and sizes, opened at different angles. This shows whether the model generalises to the variety of books in a real library.

07

Not learning the cover

A model might also pick up irrelevant cues, such as the colour of a book's cover visible at the edges of the image. If certain covers appear only with certain gutter positions in training, the model could learn a false link. Holding out whole books reduces this risk.

08

How books are bound

Bookbinding has a long history, from hand-sewn manuscripts to modern machine-made paperbacks. Bindings differ in how tightly pages are held and how far books can open. These differences change how the gutter looks in photographs, which is why testing with many bindings is important.

09

Better scanning setups

Some scanners use a V-shaped cradle that supports the book half-open, with cameras photographing each page straight on. This reduces gutter shadows and curvature, making pages easier to process. Software must still handle books scanned in other ways.

10

Responsible testing

The NIST AI Risk Management Framework encourages developers to check whether AI systems rely on features that may not hold in real use. For a gutter detector, shadows are such a feature, and the moving-light test checks for it directly.

11

Curved text lines

Near the gutter of a book that does not open flat, lines of text curve and become compressed. Finding the gutter accurately helps software straighten these lines, a process called dewarping, which greatly improves the readability of the scanned page and the accuracy of text recognition.

12

Single pages

Some scanners photograph one page at a time, which changes where the gutter appears in each image.

13

Try the arithmetic

If a model's predicted gutter shifts by 15 pixels when the light moves from left to right, while the true junction stays fixed, the model is following the shadow by that amount.

14

The idea to take away

A deep gutter casts a shadow, but a flat-opening book may show little darkness. Label the actual page junction, test with light from opposite sides, and use unseen books and opening angles, to check that the model follows the junction, not the shadow.

FOLLOW THE EVIDENCE

Sources & further reading

Figures in the example are illustrative. Photograph: original AI-generated illustration (Adobe Firefly), created for this story. Reference organisations do not endorse this website.