image op• データ種: image2d × image2d → table
• 呼び出し: import fullseye as fs; fs.ledger.harmonic_rotation(image, reference, orders=(3, 4, 5), rings=((14, 24), (30, 40), (46, 56)), center=None, tol=0.05) -> 'dict' (実装を直接呼ぶなら import residue; residue.harmonic_rotation(image, reference, orders=(3, 4, 5), rings=((14, 24), (30, 40), (46, 56)), center=None, tol=0.05) -> 'dict'、台帳から引くなら opsresidue.get("harmonic_rotation"))
Absolute in-plane rotation of image relative to reference over 360 degrees -> dict.
A feature with n-fold symmetry (n lobes, n holes, n slots) tells the rotation only modulo 360/n degrees: its order-n circular harmonic has phase n*theta. Features of several orders, each ambiguous alone, fix theta uniquely whenever the orders have no common divisor (3 and 4: 360 / gcd = 360). This op samples each annulus rings[i] (radii in px around center, default the image centre), takes the order orders[i] angular Fourier coefficient of image and reference, and solves the angle by residue_crt with the coefficient amplitudes as weights.
Returns {"angle_deg", "per_order_deg", "residual_deg", "margin", "suspect", "amplitude"}. angle_deg is counter-clockwise on screen (rows down) — the convention of scipy.ndimage.rotate — in [0, 360). suspect is the index of the ring whose residual is worst relative to its period (or -1 if all are within tol) — a smudged, occluded or broken feature shows up there before it corrupts the angle. With >= 3 orders and only one corrupted, residue_fault_locate gives a hard decision; this op keeps the soft one.
Rotate greyscale images (interpolate, then threshold if needed): rotating a binary mask with nearest-neighbour sampling roughens the edges and biases the harmonics.
• サンプルデータ カタログ(DL URL / ライセンス) — 2-D は skimage.data(BSD/public)+ 合成、3-D は実データ源(Stanford/PDS 等)の DL URL。
• 演算子の来歴・参考文献 — この op 族の元になった研究/手法の出典。
• アルゴリズムの正典(著者・年)と用途は上記ファミリ使い方ガイドに記載。
• poc_residue_crt — py -3.11 examples/poc_residue_crt.py
table を入力に取れる)—
image)*Provenance: residue.py — RESIDUE operator registry. この per-op ノートは tools/opdocs.py md が自動生成(手編集しない)。*
© 2026 Kazufumi Furuse — Fullseye operator documentation. Licensed under Apache-2.0.