NiVO / BY TECHNOGISGermany · Indonesia
Survey data workflows

FlatGeobuf Spatial Index: A Drone Inventory Export and Review Tutorial

Create an indexed FlatGeobuf derivative from a drone-derived vector inventory, then review schema, identifiers and spatial-filter results before handoff.

FlatGeobuf Spatial Index: A Drone Inventory Export and Review Tutorial

Agree which inventory the file represents

A drone-derived asset inventory may contain interpreted points, inspection lines or mapped polygons that a recipient needs to query by area. FlatGeobuf is one possible exchange format for that vector layer. Before choosing it for a NiVO survey handoff, agree the intended geometry, attributes, coordinate reference and receiving software. A compact file that opens quickly still needs a clear analytical meaning. This tutorial creates a separate indexed derivative from an identified local vector layer and outlines acceptance checks. It does not claim that a particular NiVO aircraft records FlatGeobuf directly or that a real customer inventory was converted during article preparation.

Keep the accepted master unchanged and record its revision, producing application and stable feature identifier. Specify whether the layer represents observations, interpreted objects, coverage footprints or another product. Those meanings are not interchangeable merely because each can be drawn on a map. Name any evidence photographs or supporting tables that must remain linked after export. A file-format decision should follow that delivery contract. If a recipient expects editable project relationships or application forms, test that requirement separately rather than assuming that a single vector export carries everything visible in the original GIS project.

Understand the index and creation constraints

The FlatGeobuf project describes an optional packed Hilbert R-tree index for bounding-box spatial access. Its published layout separates a header, optional index and feature data. This makes the presence of an index a representation choice, not a guarantee about the quality of mapped objects. The GDAL driver exposes SPATIAL_INDEX as a layer creation option, enabled by default. The example sets it explicitly so that the processing record states the intended output. Do not infer a measured speed improvement for your inventory from the format description; actual behavior depends on the dataset, reader and access pattern.

Review the writer constraints before a large export. GDAL currently documents that null geometries are unsupported when indexed creation is enabled, and that building the index requires memory and may use temporary files. Identify records lacking geometry and agree how they remain accounted for; silently dropping them would change the inventory. Confirm that the output location and temporary workspace suit the task. A single fgb file holds one layer, so choose the intended source layer explicitly. If several layers are required, define the package structure instead of treating one successful export as evidence that the complete project was delivered.

Restored NiVO VTOL V3 product image from the supplied brochure
Restored NiVO VTOL V3 product image from the supplied brochure.Source: NiVO / TechnoGIS catalogue materials supplied by the site owner · Catalogue photo
Product context only; this photograph does not depict the constructed examples in this article.

Inspect the source and write a fresh derivative

Use a read-only summary to confirm the source layer, geometry type, reference definition, fields and reported count. The illustrative commands below select asset_inventory from accepted-survey.gpkg and create inventory.fgb with the same layer name. Replace those local names with the identified project inputs and choose an unused destination. The conversion specifies a format and layer creation option, without asking to append, update, overwrite, simplify or reproject. Establish the correct source interpretation before adding any coordinate operation. A format conversion cannot resolve an undocumented reference merely because the resulting layer appears in a familiar map window.

The commands are checked against the current GDAL documentation as a teaching recipe; no actual project export or runtime benchmark is reported here. Record the installed GDAL version, command and input identity when carrying out the procedure. Review the complete command result and investigate warnings or failure before presenting the derivative as accepted. The read-back summary is an initial comparison, not a substitute for examining features. If an output already exists from a previous attempt, preserve its identity and choose a new revision rather than accidentally confusing an older file with the result of the latest processing run.

# Illustrative local names; keep the accepted master unchanged.
ogrinfo --version
ogrinfo -ro -so accepted-survey.gpkg asset_inventory
ogr2ogr -of FlatGeobuf -lco SPATIAL_INDEX=YES -nln asset_inventory inventory.fgb accepted-survey.gpkg asset_inventory
ogrinfo -ro -so inventory.fgb asset_inventory

Check attributes and geometry after reopening

Open the derivative independently in the actual receiving application. Compare the agreed feature identifiers, required fields, geometry type, reference and representative records against the source. Include identifiers with leading zeros, nullable attributes, dates and any measurement units that matter to the contract. Use stable project identifiers to make those comparisons; a row position or an application-generated identifier is a weak link between exports. If records were intentionally excluded under an approved rule, account for them explicitly. Matching a total count alone cannot show that every required attribute and relationship survived the exchange correctly.

Inspect features near the inventory extent as well as ordinary interior features, and include unusual or multipart geometries where they occur. Trace a linked evidence item from an exported identifier if the workflow depends on that connection. The GDAL driver offers VERIFY_BUFFERS, enabled by default, for checking buffers during reading; that protection does not establish geometry validity, correct interpretation or survey accuracy. Keep those reviews distinct. A reader can successfully decode a structurally acceptable file containing an incorrectly identified asset, an unsuitable reference definition or an analytical attribute whose unit was never documented.

Treat a spatial-filter result as a defined query

Select an area of interest whose coordinate reference and units are known, then record its bounds with the query result. GDAL ogrinfo supports a rectangular spatial filter through -spat, with minimum and maximum coordinate arguments. Use bounds expressed for the layer being inspected and verify their placement before interpreting the selection. A query window is not a statement about complete acquisition coverage, and a returned feature is not necessarily a fully observed object. For a drone inventory, distinguish the location of an interpreted asset from the imagery footprint or evidence extent used to support that interpretation.

The OGRLayer API warns that spatial filtering may return extra candidates based on overlapping envelopes. Accordingly, when the analytical requirement is an exact intersection with an irregular site boundary, validate that relationship with an appropriate geometry operation in the receiving workflow. Do not label every candidate as lying inside the site merely because an indexed request returned it. As a constructed example, an L-shaped feature can have a rectangular envelope overlapping a query window placed in its empty corner. This illustrates a geometry relationship only; it is not an observed NiVO survey feature or a claim that every driver always returns that extra candidate.

Separate local acceptance from remote delivery

The FlatGeobuf project describes partial HTTP access using range requests. That capability still depends on the actual client and server path. A successful local read does not demonstrate that a hosted copy, cache or browser integration will honor the same access pattern. If remote use is part of the agreed delivery, test that published copy separately with authorization and record the observed behavior. Keep the result scoped to the tested environment. Do not promise a particular download volume, browser response time or universal compatibility from a local conversion or from the existence of an index alone.

Deliver a short record naming the accepted source, derivative revision, selected layer, explicit index option, software version, stable identifier field and receiving-application checks. Include the defined spatial query, its intended meaning and any separate exact-geometry assessment. Retain unresolved records and limitations with the handoff instead of allowing a smooth map display to conceal them. For NiVO technical discussions, this record helps explain whether a question concerns vector packaging, spatial access, feature interpretation or the quality of the original observations. Each requires its own evidence, and none is established solely by a successful FlatGeobuf export.

Technical references

  1. FlatGeobuf project — layout, optional index and HTTP access ↗
  2. GDAL FlatGeobuf driver — creation options and constraints ↗
  3. GDAL ogr2ogr — explicit format, layer and creation options ↗
  4. GDAL ogrinfo — read-only summaries and spatial filters ↗
  5. GDAL OGRLayer — spatial-filter envelope behavior ↗
← All articles

Related articles

All articles ↗
LET’S TAKE FLIGHT

Your next mission
starts with a conversation.

Talk to our team