AI Segmentation for QGIS: The Complete Guide


AI Segmentation turns the imagery you already have open in
QGIS into clean vector layers. It works two ways. First, Automatic mode, where you draw a zone, name the object, and get every instance at once (building footprints, parcels, trees, roads, solar panels): it runs in the cloud, no GPU on your machine. Then Manual mode, a semi-automatic model that runs locally on your computer, unlimited: you click one object and the AI outlines it. The image above is a single Automatic run, and this guide walks through it live in QGIS, setting by setting.
Install and activate
In QGIS, open Plugins -> Manage and Install Plugins, search for AI Segmentation, and install. Then sign in from the panel (a browser tab, about 15 seconds) and both modes are ready.

Your first detection
Goal: extract every building footprint of the residential neighborhood above. One run, start to finish.
Draw your zone
Click Start Automatic AI Segmentation, then click around the area on the map and close the loop. Crisp, well-contrasted imagery gives the cleanest polygons.
Name the object
Type the object (here building), or pick it in the Library of ready-made objects with previews.

Show an example (optional)
One word is not always enough. Draw an example hands the AI a sample from your own imagery (same sensor, season, and resolution): outline one object, the AI looks for its look-alikes. Exclude a look-alike does the opposite: outline a false positive to tell the AI "not this". A few examples plus a name is usually the strongest combination, and examples alone work when the object has no good name.
Set the Detail
The Detail slider splits your zone into a grid of 1024 px tiles, each detected at full resolution and stitched back into one seamless layer, so objects crossing a seam are merged. Finer detail cuts smaller tiles and finds smaller objects; the tile count updates live (here 9 tiles). There is no size limit on the zone.

Detect
Click Detect objects. The zone is processed tile by tile and results draw live on the map. This run found 951 candidate objects.


Review
Detection opens a review, not an export. Everything below is instant and needs no re-run: you filter and reshape the detections until the layer looks right. The next section goes through each control.

Export
Click Export polygons. You get a styled GeoPackage layer with a GIS-ready schema: class, score, area_m2, perimeter_m. Here, 335 building footprints.


The review controls, explained
Confidence
Every detection carries a score: how sure the AI is that this polygon really is your object. The run returns everything plausible, and the Confidence slider sets the minimum score to keep: drag toward More objects to reveal weaker detections, toward Only confident to keep only the strongest. The histogram above the slider shows how many objects sit at each level, and the count updates live. The same run, swept live between More objects and Only confident:
Dense, repetitive objects like these roofs score modestly, so starting low and pruning up usually beats the reverse. Objects you fixed by hand are always kept, whatever the confidence.
Display colors
Four ways to look at the same detections, each answering a different question. Random (one color per object) checks that neighbors are separated. Outline checks boundaries against the imagery. Confidence shows where the AI is sure (yellow) or hesitant (purple), which tells you where to point the confidence slider. Normal is a single clean color. Visual only, the geometry never changes.

Refine detections
The Refine detections section reshapes every polygon at once, instantly:

- Right angles snaps edges to 90 degrees, for man-made shapes like buildings, pools and solar panels.
- Round corners softens outlines, for natural shapes like trees and bushes.
- Fill holes closes interior gaps in each polygon.
- Min / Max size hides detections outside a ground-area range, the fastest way to drop tiny noise blobs.
- Simplify outline, Clean edges and Expand/Contract fine-tune the outline itself.
The same trick on anything
Automatic mode is one input away from a completely different job: change the word, get another layer. Farm parcels over 5 km²:


Or the panel arrays of a solar farm:


Trees, cars, greenhouses, pools, solar panels all work the same way; the Library in the panel lists ready-made objects with previews if you'd rather not guess the wording.
Manual mode
Manual mode is a semi-automatic model that runs locally on your own machine, unlimited and offline, after a one-time one-click setup from the panel. The interaction is always the same: you click an object and the AI outlines it in one shot, then left-click adds area and right-click excludes a stray part, so a couple of clicks turn a rough guess into a clean boundary. The same shape controls as Automatic (Simplify outline, Round corners, Right angles, Expand/Contract, Fill holes) apply to the live selection. Save polygon commits it (it turns green), you move to the next object, and Export polygons to a layer writes them all out when you are done.

Manual mode earns its place two ways, and the fastest way to meet it is as a repair tool for an Automatic run.
Fix an Automatic result by hand
An Automatic pass gets you most of the way, but a dense scene always leaves a few rough edges: one outline that bleeds into a neighbour, a courtyard the model split in two, a handful of buildings it never caught. Right inside the review, Refine in Manual mode opens those exact detections in Manual so you can correct them point by point, with nothing re-run and no new credits spent.

Every detection comes across as an editable object. Right-click inside one to re-open it and carve away an over-segmented part; left-click inside it to grow it back. Click empty ground to add a building the pass missed, Delete drops one you do not want, and S keeps the one you are happy with (it turns green). When the layer is right, go Back to review and export the automatic and hand-made polygons together.
Segment from scratch, object by object
You can also skip Automatic entirely and segment element by element, each with its own clean outline. Because the model runs on your machine it is unlimited and costs no credits, which makes it the right tool when you need ten precise objects rather than a thousand, or when you want full control over every boundary. Same imagery rule as Automatic: any visible raster works, from a GeoTIFF to a drone orthophoto to an XYZ/WMS basemap.
Pick Manual and start
In the panel, keep the Manual tab selected, choose your imagery layer, and click Start Manual AI Segmentation. The model loads once, then every click is instant.
Click an object
Click anywhere on the object and the local model outlines it in one shot. Here, a single click on an isolated building.

Correct it with a click or two
Left-click adds area the model missed; right-click excludes a part it grabbed by mistake. The outline updates on every click. The green dot is a positive point, the red cross a negative one.

Save and move on
Save polygon (or press S) commits the selection: it turns green and joins the layer, and the panel is ready for the next object. The model works best one element at a time.

Export to a layer
When you have all your objects, Export polygons to a layer writes a styled GeoPackage with a clean schema (label and area_m2), ready for the GIS.

Try it on your own map
The best test is a zone you actually work on: install AI Segmentation, run it there, and compare the layer with what you would have digitized by hand. And if anything behaves oddly, the ? Help button in the panel reaches us directly.