1 vin.types.model_inputs
vin.types.model_inputs
Model-input containers shared by VIN scorer implementations.
This module owns dataclasses for intermediate tensors assembled during VIN forward passes. They are separate from helper functions so models, diagnostics, and tests can depend on explicit contracts without importing utility buckets.
1.1 Classes
| Name | Description |
|---|---|
| FieldBundle | Voxel-aligned scene-field tensors built from actor-visible EVL outputs. |
| GlobalContext | Pose-conditioned global scene context tensors. |
| PoseFeatures | Reference-rig-frame features for VIN candidate views. |
| PreparedInputs | Prepared inputs for VIN v3-style forward passes. |
1.1.1 FieldBundle
vin.types.model_inputs.FieldBundle(field_in, field, aux)Voxel-aligned scene-field tensors built from actor-visible EVL outputs.
1.1.1.1 Attributes
| Name | Description |
|---|---|
| field_in | Tensor["B C_in D H W", float32] raw scene field. |
| field | Tensor["B C_out D H W", float32] projected scene field. |
| aux | Auxiliary channels, such as normalized counts and occupancy probabilities. |
1.1.2 GlobalContext
vin.types.model_inputs.GlobalContext(pos_grid, global_feat)Pose-conditioned global scene context tensors.
1.1.2.1 Attributes
| Name | Description |
|---|---|
| pos_grid | Tensor["B 3 D H W", float32] normalized voxel position grid. |
| global_feat | Tensor["B N_q C", float32] pose-conditioned global features. |
1.1.3 PoseFeatures
vin.types.model_inputs.PoseFeatures(pose_enc, pose_vec, candidate_center_rig_m)Reference-rig-frame features for VIN candidate views.
1.1.3.1 Attributes
| Name | Description |
|---|---|
| pose_enc | Tensor["B N_q E", float32] pose encoder output. |
| pose_vec | Tensor["B N_q D", float32] pose vector fed into the encoder. |
| candidate_center_rig_m | Tensor["B N_q 3", float32] candidate centers in reference-rig metres. |
1.1.4 PreparedInputs
vin.types.model_inputs.PreparedInputs(
pose_world_cam,
pose_world_rig_ref,
t_world_voxel,
batch_size,
num_candidates,
device,
snippet,
)Prepared inputs for VIN v3-style forward passes.
1.1.4.1 Attributes
| Name | Type | Description |
|---|---|---|
| pose_world_cam | PoseTW |
PoseTW["B N_q 12"] world-from-camera candidate poses. |
| pose_world_rig_ref | PoseTW |
PoseTW["B 12"] reference rig pose in world frame. |
| t_world_voxel | PoseTW |
PoseTW["B 12"] world←voxel pose for the EVL voxel grid. |
| batch_size | int | Batch size inferred from candidate poses. |
| num_candidates | int | Number of candidate views per batch item. |
| device | torch.device | Device used for tensors in the forward pass. |
| snippet | VinSnippetView |
VIN snippet view with padded semidense evidence. |