Tiling
Boost small-object detection using tiling. Learn four strategies to tile, detect, and merge results effectively in PySDK.
Estimated read time: 6 minutes
High-resolution scenes with many small objects often benefit from tiling: you split the image into overlapping tiles, run detection per tile, then merge the results. Tiling typically improves small-object recall, but can introduce duplicates near tile borders or reduce large-object accuracy.
degirum_tools provides four ready-made strategies. TileModel, LocalGlobalTileModel, BoxFusionTileModel, and BoxFusionLocalGlobalTileModel.
Think of the four modes as incremental layers:
TileModel is the baseline: only tile inference plus optional NMS. Small objects pop, but large ones can fracture or vanish at tile seams.
LocalGlobalTileModel adds a global pass. After the tile run, any object whose area exceeds
large_object_thresholdis replaced with the global detection. It is an error-correction sweep that restores large objects without changing the grid.BoxFusionTileModel keeps tile-only inference, but cleans up seam artifacts by performing a 1-D IoU fusion inside an edge band (
edge_threshold). Boxes that overlap across tile borders are merged instead of duplicated.BoxFusionLocalGlobalTileModel combines both upgrades: seam fusion and global rescue. Use it when you need the most faithful merged view—large and small targets, minimal duplicates.

The white square shows the current tile being processed. The final yellow and green boxes are the detections produced by the tiling strategy.
The caption under the gif indicates the model, tile grid and overlap, mode, and runtime.

Observe how there's an additional scan of the entire image. Compared to a plain old TileModel, LocalGlobalTileModel adds a final global scan and the large_obj threshold.
The caption again lists the model, grid/overlap, mode/runtime, and—new in this mode—the large_obj threshold that decides when to keep the global detection.

Here the tiles behave the same as in TileModel, but seam duplicates disappear before the green boxes are drawn.
Unlike LocalGlobalTIleModel, there's no global scan with BoxFusionTileModel.
The caption still lists the model and grid, and now the third line includes the edge and fusion thresholds that control the seam-aware box merging.

This mode stacks improvements from LocalGlobal and BoxFusionTileModels.
The caption summarizes everything—model, grid, mode/runtime—and lists both large_obj and the box-fusion thresholds.
Every command and JSON output in the demo includes these thresholds so you can tell at a glance which pipeline produced the result.
Example (ModelSpec + remote_assets)
Last updated
Was this helpful?

