panel_grid — ANNOTATE compose op

Data kinds: image2dimage2d

Call: import annotate; annotate.panel_grid(panels, labels=None, ncols=3, pad=10, label_h=32, background=0.05, title=None, title_h=0, font_size=15, min_font_size=9, font_path=None, text_color=None, border=0, border_color='neutral', scheme='okabe_ito', style=None) (or opsannotate.get("panel_grid"))

Usage

Lay panels out on a grid, with a label strip under each frame (montage / contact sheet).

> The detailed description below is the original text — the summary and the headings are translated.

生成器 6 本がそれぞれ別実装を持っていた、**この repo で最も重複していた図の

部品**。ここでの流儀:

拡大しない ―― 小さいパネルは中央に置いて余白で埋める。引き伸ばすと

「無い解像度がある」ように見える。

ラベルは測ってから描く ―― 入らなければ縮め、駄目なら例外

(:func:text_box の境界検査に載る)。

• セルの大きさは全パネルの最大寸で、格子は常に矩形

Parameters

----------

panels : sequence of ndarray

並べる画像(`(H,W) / (H,W,C)`、大きさはばらばらでよい)。

チャンネルの並びは揃っていること。

labels : sequence of str or None

各パネルの見出し。`label_h` が 0 なら描かない。

ncols : int

列数。行数は `ceil(n/ncols)`。

title : str or None

全体の表題(`title_h が 0 なら font_size+14` を自動で確保)。

Returns

-------

ndarray

新しい合成画像(float [0,1])。大きさは

`W = 2*pad + ncols*cw + (ncols-1)*pad`、

`H = title_h + 2*pad + nrows*(ch+label_h) + (nrows-1)*pad`。

Raises

------

ValueError

panels が空 / チャンネル不一致 / ncols < 1 / 負の余白 /

labels の数が合わない。

Detailed usage guide

figure_annotation family guide

Background guides (the physics and conventions behind this op)

dataset_conventions — 学習データセット規約の知識 — COCO / YOLO / VOC と外観検査での落とし穴

References (sample data, literature)

• Sample-data catalog (download URLs / licences) — 2-D uses skimage.data (BSD/public domain) plus synthetic images; 3-D lists download URLs for real data sources (Stanford, PDS, …).

• Operator provenance and references — the sources of the research/methods this op family came from.

• The canonical algorithm (author, year) and its uses are named in the family usage guide above.

Runnable examples (verified samples that actually call this op)

annotate_gallerypy -3.11 examples/annotate_gallery.py

Ops the type connects to (they accept image2d as input)

text_box · arrow · leader_line · label_points · crosshair · legend_box · color_bar · scale_bar

Same category (compose)

zoom_inset · compare_frame


*Provenance: annotate.py — ANNOTATE operator registry. This per-op note is generated by tools/opdocs.py md (do not hand-edit).*

© 2026 Kazufumi Furuse — Fullseye operator documentation. Licensed under Apache-2.0.