Layout Knowledge Base

Size and grid

Database units: how layout files store coordinates as integers

A GDSII or OASIS file stores every coordinate as a whole number of database units. How that scale becomes microns, and what breaks when tools disagree.

Last edited: September 30, 2026

That integer bargain drawn large: an uneven octagon whose corners you can name, beside a smoother chain that still lands every corner on a whole tick.

You want a metal stripe to come out the width you measured, after the file keeps only whole numbers.

Each of those whole numbers is a database unit, one tick. The drawing does not store "2.000 micrometers" as a decimal width. It stores an integer, and a scale elsewhere in the file says how long one tick is in the real world. The same 2000 ticks are 2 micrometers when one micrometer is 1000 ticks, and 1 micrometer when a second tool assumes 2000 ticks per micrometer. Stretch that integer to 4000 to "repair" the narrow reading and you have 4 micrometers on the original scale, wide enough for the stripe to meet its neighbor. Change the integer and one edge moves by ticks. Change the scale and every edge in the file changes length together, while the integers sit still. Designers talk in micrometers because chip features are small beside a human hair and large beside a nanometer; why chip people live in microns sets those three lengths on one photograph. The picture at the top of this page is that integer bargain drawn large: an uneven octagon whose corners you can name, beside a smoother chain that still lands every corner on a whole tick.

Counting the ticks in a gap

The second picture is two pairs of rectangles, so you can see what a tick error does to a space.

Two pairs of teal and navy rectangles: the upper pair has a wide gap, and the lower pair overlaps.

The upper pair has a wide gap between the rectangles. The lower pair uses the same two sheets and has no gap. The rectangles overlap, and the overlap paints darker where the fills stack. In this drawing the upper gap is 2000 ticks wide, and the lower overlap is 1600 ticks. At 1000 ticks per micrometer, the upper space is 2 micrometers and the lower overlap is 1.6 micrometers. Those are not subtle numbers once you count. On a zoomed-out screen both pairs can look like two blocks near each other. A hairline gap, one or two ticks of white, is the dangerous step between a space you can see and an overlap. Round that hairline the wrong way and you get the lower pair: the space becomes a short.

The scale lives in the file header. In GDSII, a stream file of cells and shapes, a units record states how big one database unit is in user units and in meters. A classic teaching pair is a user unit of 0.001 and a meter size of one nanometer per tick, which is 1000 ticks per micrometer. OASIS states a grid step per micrometer and means the same contract. In a GDSII stream the units record comes before the first cell, so every rectangle, path, and polygon record after it is read on that scale; GDSII in plain language walks through those records one at a time. Ignore the header, or let a second tool assume a different one, and the integers stay polite while the chip changes size.

All snap, all grid, and every half-micrometer click become integers before they are stored. If you ask for a point the tick cannot represent, the editor rounds. Rounding is a real move of an edge. At 1000 ticks per micrometer, half a tick is half a nanometer and must become either 0 or 1 tick. A boolean invents intersection points that also have to land on ticks. A width that started as a clean number can come back one tick smaller, and a design-rule check then reports a failure that looks like a drawing bug.

Two tools reading one integer

A block was streamed at 1000 ticks per micrometer. A second tool imported it assuming 2000 ticks per micrometer. Every coordinate kept its integer. The importer treated each tick as half as long. A line stored as 2000 ticks, which was 2 micrometers, was read as 1 micrometer. Someone repaired the width by stretching the integer to 4000. On the original scale, 4000 ticks is 4 micrometers. Metal that should have kept a 2 micrometer space grew until it met its neighbor. The wafer shorted. Both screens had shown calm integers the whole time. The upper pair in the second picture is the space you think you have when the scale is shared. The lower pair is the overlap you build when one tool is silently on a different scale, or when a one-tick rounding closes a hairline.

Know the tick. Know the manufacturing grid, which is often coarser than one tick. A tick of 1 nanometer does not make a 1 nanometer corner legal if the writer demands 5 nanometers. Storability is a different question from legality. When a number crosses from a board tool, which may think in millimeters, into this integer file, write the unit in the same sentence as the number and recompute the ticks yourself.

Open the file header and read the units record before you trust a width from a second tool. Then measure the upper gap in the second picture as a tick count, and divide by the ticks per micrometer you read. If that quotient is not the micrometers you meant, the integers and the scale have already parted company. Do that division on one stripe before you let anyone stretch a coordinate to make a screen look right.

Divide the gap before you stretch anything

Open the file header and read the units record. In this drawing, 1000 ticks is 1 micrometer and 2000 ticks is 2 micrometers. The upper gap in the second picture is 2000 ticks. At 1000 ticks per micrometer that is 2 micrometers. The lower overlap is 1600 ticks, 1.6 micrometers, and it is an overlap, not a gap. If a second tool calls the upper gap 2.000 and means millimeters, or calls the 1600 ticks a space, the integers and the scale have already parted. Stretching a coordinate to make the screen look right will bake the wrong scale in.

A tick of 1 nanometer does not make a 1 nanometer corner legal when the writer wants 5 nanometers. Storability is not legality. When a number arrives from a board tool that thinks in millimeters, write the unit in the same sentence as the number and recompute the ticks yourself. Do that division on one stripe before anyone else touches the file.

Continue exploring