visual_hull — 3D space_carving op

Data kinds: imagesvoxel

Call: import fullseye as fs; fs.ledger.visual_hull(silhouettes: 'Sequence[np.ndarray]', Ks: 'Sequence[np.ndarray]', Rs: 'Sequence[np.ndarray]', ts: 'Sequence[np.ndarray]', bounds: 'Bounds', res: 'int') -> 'np.ndarray' (to call the implementation directly, import visualhull; visualhull.visual_hull(silhouettes: 'Sequence[np.ndarray]', Ks: 'Sequence[np.ndarray]', Rs: 'Sequence[np.ndarray]', ts: 'Sequence[np.ndarray]', bounds: 'Bounds', res: 'int') -> 'np.ndarray'; from the registry, ops3d.get("visual_hull"))

Usage

Return the visual hull of multi-view silhouettes as voxel occupancy (an alias of :func:carve).

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

引数・返り値・例外は `carve と完全に同じ(内部でそのまま carve` を呼ぶだけ)。

• `silhouettes`: 各カメラの前景マスク (H,W) bool を M 個並べたリスト(サイズはカメラごとに

異なってよい)。

• `Ks/Rs/ts`: 各カメラの内部行列 (3,3)・回転 (3,3)・並進 (3,)。射影規約は

`X_cam = R @ X_world + tpixel = (K @ X_cam)[:2] / Z`(OpenCV 流)。画素は最近傍に丸める。

• `bounds: ((xmin,xmax),(ymin,ymax),(zmin,zmax))` の彫刻領域(各軸 max > min 必須)。

• `res: 各軸の voxel 分割数(正の整数)。voxel 総数 res**3`。

返り値は (res,res,res) bool。`indexing='ij' で軸は (x,y,z)、vox[i,j,k]` の中心は

`(xmin+(i+.5)dx, ymin+(j+.5)dy, zmin+(k+.5)dz)`。voxel が残る条件は、全カメラで「カメラ前方

(Z>0)・画像内・その画素がシルエット前景」を満たすこと(AND)。1 台でも外れれば削られる。

fail-closed: リスト長の不一致、カメラ 0 台、`res <= 0、退化 bounds はすべて ValueError`

(0 台のときに「全 voxel 占有」を復元結果と偽って返さない)。

注意: visual hull は物体の上位集合で、どのカメラからも見えない凹みは埋まったまま残る。

シルエットは `synthesize_silhouette` のように 1 画素太らせた被覆マスクにしておくと、離散化

誤差で物体 voxel を削り落とす取りこぼしを避けられる。結果は `voxel_to_mesh` でメッシュ化、

`esdf` の占有入力にもそのまま使える。

Background guides (the physics and conventions behind this op)

blender_interop — Blender との併用 — 形を作って fullseye で測る(軸・単位・正解データの罠)

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.

Runnable examples (verified samples that actually call this op)

space_carvingpy -3.11 examples_3d/space_carving.py

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

voxel_to_mips · voxel_to_mesh · signed_distance_field · to_points · sobel3d · hessian3d · curvature_maps · edt_jfa

Same category (space_carving)

carve · synthesize_silhouette · carve_look_at


*Provenance: visualhull.py — 3D 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.