ssim — IMGMETRICS fidelity op

Data kinds: image2d × image2dscalar

Call: import imgmetrics; imgmetrics.ssim(a, b, data_range=None, win_size=11, sigma=1.5, K1=0.01, K2=0.03, channel_axis=None, crop_border=True) (or opsimgmetrics.get("ssim"))

Usage

Structural similarity (Wang, Bovik, Sheikh & Simoncelli, IEEE TIP 13(4), 2004).

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

既定は原論文の設定 ―― 11x11 のガウシアン窓 σ=1.5、K1=0.01、K2=0.03

重み付き分散(標本分散への `n/(n-1)` 補正を入れない)。

`crop_border=True`(既定)は窓の半径ぶんの縁を平均から落とす。縁では

鏡像で埋めた画素が統計に混ざるため。落とすかどうかで値が変わるので、

他所の数値と比べるときは必ずこの設定を揃えること(小さい絵ほど差が出る)。

Returns

-------

float

1.0 が完全一致。

Detailed usage guide

image_difference_metrics family guide

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)

image_quality_metricspy -3.11 examples/image_quality_metrics.py

poc_camera_shake_deblurpy -3.11 examples/poc_camera_shake_deblur.py

poc_ct_fidelitypy -3.11 examples/poc_ct_fidelity.py

poc_dehazingpy -3.11 examples/poc_dehazing.py

poc_superresolution_limitspy -3.11 examples/poc_superresolution_limits.py

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

Same category (fidelity)

mse · rmse · psnr · ms_ssim · ssim_map


*Provenance: imgmetrics.py — IMGMETRICS 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.