legend_box — ANNOTATE furniture op

Data kinds: image2d × entriesimage2d

Call: import annotate; annotate.legend_box(img, entries, xy, anchor='lt', swatch=14, row_gap=4, pad=8, font_size=13, box_color=None, box_alpha=0.72, markers=False, scheme='okabe_ito', font_path=None, min_font_size=9, style=None, border=1, border_color='neutral') (or opsannotate.get("legend_box"))

Usage

A legend of colours against descriptions. The box height follows in closed form from the number of entries.

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

`height = 2*pad + n*row_h + (n-1)*row_gap (`row_h = max(swatch, 文字高))。

Parameters

----------

entries : sequence

`(color, text) の並び。color` は役割名でも RGB でもよい。

markers : bool

True なら役割名に対応する :data:palette.ROLE_MARKERS の記号を

説明の前に付ける(色だけに意味を載せないため)。役割名でない

要素には記号が無いので付かない。

Returns

-------

ndarray

Raises

------

ValueError

entries が空 / 形が `(color, text)` でない / 箱が画像からはみ出す /

未知の役割名。

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 · color_bar · scale_bar · axes_frame

Same category (furniture)

color_bar · scale_bar


*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.