tacscalib op• 資料種類:matrix × matrix → table
• 呼叫: import fullseye as fs; fs.ledger.gradient_lut_build(rgb_rows, normal_rows, bins: 'int' = 125, positions=None, image_shape=None, flat_rgb=None, flat_positions=None, min_rows_poly: 'int' = 30, ridge: 'float' = 0.001, pool: 'bool' = True) -> 'dict'(要直接呼叫實作,import tacscalib; tacscalib.gradient_lut_build(rgb_rows, normal_rows, bins: 'int' = 125, positions=None, image_shape=None, flat_rgb=None, flat_positions=None, min_rows_poly: 'int' = 30, ridge: 'float' = 0.001, pool: 'bool' = True) -> 'dict';從台帳取用則 opsdrive.get("gradient_lut_build"))
example-based 梯度 LUT:將法線的(傾角 θ,方位 φ)劃分為 bins × bins,在每個 bin 中存入落入其中的像素 RGB 的平均值(以 np.add.at 把重複的索引也全部累加)。rgb_rows (P, 3)、normal_rows (P, 3)。
給出 positions((P, 2) = (列, 行))與 image_shape 時為位置相關版:對列數不少於 min_rows_poly 的 bin 擬合 RGB = 6 個係數 · [x², y², xy, x, y, 1] (x, y 依影像尺寸縮放到 −1..1,除常數項外加小的 ridge)。pool=True 時, 列數少的 bin 借用角度上最近的多項式 bin 的位置項(5 個係數),只把常數項對齊到自身各列的平均 —— 若只在擬合了位置項的 bin 中查找,斜率小的 bin 全部落空,0〜15° 成為盲區(試作時踩過的坑)。flat_rgb((F, 3),位置版還要 flat_positions (F, 2))作為「平坦樣例」= 法線 (0, 0, 1) 加入的列(如遠離接觸的環,弱真值)。
回傳:bins、mean_rgb (bins, bins, 3)(空 bin 為 nan)、count (bins, bins)、centre_normals (bins, bins, 3)、n_rows、n_flat、coef((bins, bins, 6, 3) 或 None)、basis("unit")、image_shape、poly_bins· pooled_bins(擬合了 / 借用了位置項的 bin 數)。Raises ValueError:形狀不一致 / bins < 4 / min_rows_poly < 6 / 列數為 0 / 非有限值 / positions 與 image_shape 只給了一個 / 只給了 flat_positions。
• 範例資料目錄(下載 URL / 授權) —— 2-D 用 skimage.data(BSD/公有領域)加合成圖,3-D 給出真實資料源(Stanford/PDS 等)的下載 URL。
• 運算子來歷與參考文獻 —— 該運算子族所依據的研究/方法出處。
• 演算法的正典(作者、年份)與用途見上面的族使用指南。
• poc_tacscalib_sphere_lut — py -3.11 examples/poc_tacscalib_sphere_lut.py
table 作為輸入)course_layout · course_occupancy · course_contains · world_build · world_camera · world_move · lidar_scan · rss_longitudinal_same
tacscalib)calib_pack_load · sphere_normals_known · lights_fit_from_sphere · membrane_predict_rgb · gradient_lut_invert · normal_error_map · sphere_cap_height · field_position_sweep
*Provenance: tacscalib.py — DRIVE 運算子登記表。本條目由 tools/opdocs.py md 自動產生(請勿手動編輯)。*
© 2026 Kazufumi Furuse — Fullseye operator documentation. Licensed under Apache-2.0.