Skip to content

Comments

FOEPD-2856: Add docs for new camera model / intrinsics / extrinsics#6711

Merged
sashankaryal merged 1 commit intodevelopfrom
docs/camera
Jan 12, 2026
Merged

FOEPD-2856: Add docs for new camera model / intrinsics / extrinsics#6711
sashankaryal merged 1 commit intodevelopfrom
docs/camera

Conversation

@sashankaryal
Copy link
Contributor

@sashankaryal sashankaryal commented Jan 5, 2026

What changes are proposed in this pull request?

Documentation for intrinsics / extrinsics. Main PR is #6700

How is this patch tested? If it is not, please explain why.

Local docs build

Release Notes

Is this a user-facing change that should be mentioned in the release notes?

  • No. You can skip the rest of this section.
  • Yes. Give a description of this change to be included in the release
    notes for FiftyOne users.

(Details in 1-2 sentences. You can just refer to another PR with a description
if this PR is part of a larger change.)

What areas of FiftyOne does this PR affect?

  • App: FiftyOne application changes
  • Build: Build and test infrastructure changes
  • Core: Core fiftyone Python library changes
  • Documentation: FiftyOne documentation changes
  • Other

Summary by CodeRabbit

  • Documentation
    • Expanded user guide with comprehensive camera calibration coverage: storing/resolving camera intrinsics and sensor extrinsics, intrinsics models, 3D projection/transform workflows, and practical dataset/sample examples.
    • Added new substitutions and cross-reference entries for camera-related terms to improve readability and linking.
    • Note: content-only changes; no API or runtime behavior changes. Some sections were inadvertently duplicated.

✏️ Tip: You can customize this high-level summary in your review settings.

@sashankaryal sashankaryal requested a review from a team as a code owner January 5, 2026 21:13
@sashankaryal sashankaryal changed the title add docs for new camera model / intrinsics / extrinsics FOEPD-2856: add docs for new camera model / intrinsics / extrinsics Jan 5, 2026
@sashankaryal sashankaryal self-assigned this Jan 5, 2026
@coderabbitai
Copy link
Contributor

coderabbitai bot commented Jan 5, 2026

Walkthrough

This pull request adds documentation for camera calibration across two files. One file adds substitution definitions for camera-related constructs (CameraIntrinsics, PinholeCameraIntrinsics, OpenCVCameraIntrinsics, OpenCVFisheyeCameraIntrinsics, CameraIntrinsicsRef, SensorExtrinsics, CameraExtrinsics, CameraProjector). The other expands the user guide with dataset-level storage and resolution of camera intrinsics and sensor extrinsics, matrix constructors and transforms, resolution order, and a 3D projection workflow using CameraProjector. No code, API, or runtime changes are included.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~12 minutes

🚥 Pre-merge checks | ✅ 2 | ❌ 1
❌ Failed checks (1 inconclusive)
Check name Status Explanation Resolution
Description check ❓ Inconclusive The description addresses the main PR changes, testing method, and release notes impact. However, the release notes section lacks the required 1-2 sentence description for the user-facing change despite marking 'Yes'. Fill in the release notes description with 1-2 sentences summarizing the camera intrinsics/extrinsics documentation addition for users.
✅ Passed checks (2 passed)
Check name Status Explanation
Title check ✅ Passed The title clearly identifies the main change: adding documentation for camera models, intrinsics, and extrinsics. It directly corresponds to the changeset which adds camera-related documentation sections and substitutions.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.

✏️ Tip: You can configure your own custom pre-merge checks in the settings.


Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

Fix all issues with AI Agents 🤖
In @docs/source/user_guide/using_datasets.rst:
- Around line 5826-5875: The example uses undefined variables camera_to_ego and
ego_to_world when calling compose; update the snippet to either (A) define those
transforms using SensorExtrinsics (e.g., create camera_to_ego and ego_to_world
with SensorExtrinsics or SensorExtrinsics.from_matrix) before calling
camera_to_world = camera_to_ego.compose(ego_to_world), or (B) reuse the existing
extrinsics variable (e.g., camera_to_world = extrinsics.compose(inv_extrinsics)
or similar) so the call to SensorExtrinsics.compose references defined
SensorExtrinsics instances and the example runs correctly.
♻️ Duplicate comments (1)
docs/source/user_guide/using_datasets.rst (1)

5763-6010: Intrinsics/extrinsics, resolution, and CameraProjector docs are coherent

The new sections on camera intrinsics, sensor extrinsics, calibration resolution order, and CameraProjector provide a consistent workflow: dataset-level storage, sample-level overrides, frame naming, and projection/unprojection usage. Terminology (frames, quaternions, 3×3/4×4 matrices, chain_via, grouped group_slice behavior) is coherent and matches the earlier “Storing camera calibration” section.

Beyond the minor composition-example fix above, the content is solid.

📜 Review details

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between d5b375d and 954ac04.

📒 Files selected for processing (2)
  • docs/source/_includes/substitutions.rst
  • docs/source/user_guide/using_datasets.rst
🧰 Additional context used
🧠 Learnings (2)
📚 Learning: 2025-10-16T17:24:11.588Z
Learnt from: brimoor
Repo: voxel51/fiftyone PR: 6373
File: docs/source/dataset_zoo/datasets/ucf101.rst:32-0
Timestamp: 2025-10-16T17:24:11.588Z
Learning: In FiftyOne documentation, dataset zoo classes follow the pattern `fiftyone.zoo.datasets.base.{DatasetName}Dataset` and should be referenced using `:class:` directives (e.g., `:class:`UCF101Dataset <fiftyone.zoo.datasets.base.UCF101Dataset>``). This is a valid and established documentation pattern.

Applied to files:

  • docs/source/user_guide/using_datasets.rst
📚 Learning: 2025-11-25T15:39:52.528Z
Learnt from: paularamo
Repo: voxel51/fiftyone PR: 6619
File: docs/source/tutorials/cosmos-transfer-integration.ipynb:812-813
Timestamp: 2025-11-25T15:39:52.528Z
Learning: In the cosmos-transfer-integration.ipynb tutorial for FiftyOne grouped datasets: when computing embeddings for original images and Cosmos-Transfer generated outputs, use separate embedding fields (e.g., "image_embeddings" for original images and "output_last_embeddings" for generated outputs) to enable independent similarity analysis and comparison between the two slice types.

Applied to files:

  • docs/source/user_guide/using_datasets.rst
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: build
🔇 Additional comments (2)
docs/source/_includes/substitutions.rst (1)

72-79: Camera-related substitutions look correct and consistent

The new substitutions follow the existing pattern and point to coherent fiftyone.core.camera.* targets. No changes requested.

docs/source/user_guide/using_datasets.rst (1)

792-873: Storing camera calibration section is clear and aligned with Dataset API

The new camera_intrinsics / sensor_extrinsics docs and examples are consistent with the rest of the Dataset API documentation (naming, grouped dataset usage, dataset.save() notes, and key format "source::target"). No changes requested.

@sashankaryal sashankaryal changed the title FOEPD-2856: add docs for new camera model / intrinsics / extrinsics FOEPD-2856: Add docs for new camera model / intrinsics / extrinsics Jan 5, 2026
@sashankaryal sashankaryal force-pushed the feat/camera-params-rest branch from d5b375d to 267a96a Compare January 5, 2026 22:47
@sashankaryal sashankaryal requested a review from a team as a code owner January 5, 2026 22:47
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Fix all issues with AI Agents
In @docs/source/user_guide/using_datasets.rst:
- Around line 5826-5853: The documentation example uses undefined variables
camera_to_ego and ego_to_world when calling SensorExtrinsics.compose, which will
break; fix it by explicitly creating SensorExtrinsics instances (e.g.,
camera_to_ego = SensorExtrinsics(...), ego_to_world = SensorExtrinsics(...))
with appropriate translation/quaternion/source_frame/target_frame values and
then call camera_to_world = camera_to_ego.compose(ego_to_world); ensure variable
names match the ones used later (SensorExtrinsics, compose, camera_to_ego,
ego_to_world, camera_to_world).
📜 Review details

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 954ac04 and da013ba.

📒 Files selected for processing (2)
  • docs/source/_includes/substitutions.rst
  • docs/source/user_guide/using_datasets.rst
🧰 Additional context used
🧠 Learnings (2)
📚 Learning: 2025-10-16T17:24:11.588Z
Learnt from: brimoor
Repo: voxel51/fiftyone PR: 6373
File: docs/source/dataset_zoo/datasets/ucf101.rst:32-0
Timestamp: 2025-10-16T17:24:11.588Z
Learning: In FiftyOne documentation, dataset zoo classes follow the pattern `fiftyone.zoo.datasets.base.{DatasetName}Dataset` and should be referenced using `:class:` directives (e.g., `:class:`UCF101Dataset <fiftyone.zoo.datasets.base.UCF101Dataset>``). This is a valid and established documentation pattern.

Applied to files:

  • docs/source/user_guide/using_datasets.rst
📚 Learning: 2025-11-25T15:39:52.528Z
Learnt from: paularamo
Repo: voxel51/fiftyone PR: 6619
File: docs/source/tutorials/cosmos-transfer-integration.ipynb:812-813
Timestamp: 2025-11-25T15:39:52.528Z
Learning: In the cosmos-transfer-integration.ipynb tutorial for FiftyOne grouped datasets: when computing embeddings for original images and Cosmos-Transfer generated outputs, use separate embedding fields (e.g., "image_embeddings" for original images and "output_last_embeddings" for generated outputs) to enable independent similarity analysis and comparison between the two slice types.

Applied to files:

  • docs/source/user_guide/using_datasets.rst
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: build
🔇 Additional comments (2)
docs/source/_includes/substitutions.rst (1)

72-79: Camera substitutions look consistent with existing pattern

The new |CameraIntrinsics|/|SensorExtrinsics|/|CameraProjector| substitutions follow the same Sphinx pattern as the rest of the file and read cleanly. Just ensure the referenced classes in fiftyone.core.camera match these names so intersphinx links resolve in the built docs.

docs/source/user_guide/using_datasets.rst (1)

792-873: Dataset-level calibration section is clear and consistent

The new camera_intrinsics / sensor_extrinsics examples match existing patterns in this guide (dataset-level properties, grouped datasets, explicit dataset.save()), and the key-format explanation ("source_frame::target_frame" / "source_frame") is clear. No changes needed.

@sashankaryal sashankaryal force-pushed the feat/camera-params-rest branch from c798919 to 640a228 Compare January 7, 2026 00:36
@sashankaryal sashankaryal requested a review from a team as a code owner January 7, 2026 00:36
@sashankaryal sashankaryal force-pushed the feat/camera-params-rest branch from 640a228 to 02af9fb Compare January 7, 2026 00:43
Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

🤖 Fix all issues with AI agents
In @docs/source/user_guide/using_datasets.rst:
- Around line 5823-5875: The example uses undefined names `camera_to_ego` and
`ego_to_world`; rename the existing `extrinsics` variable to `camera_to_ego` and
add a second `SensorExtrinsics` instance `ego_to_world` (e.g., a transform from
"ego" to "world") before calling `camera_to_world =
camera_to_ego.compose(ego_to_world)` so the `compose` call uses two defined
SensorExtrinsics objects (`camera_to_ego`, `ego_to_world`) and produces
`camera_to_world`.
📜 Review details

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between da013ba and 268ffa7.

📒 Files selected for processing (2)
  • docs/source/_includes/substitutions.rst
  • docs/source/user_guide/using_datasets.rst
🧰 Additional context used
🧠 Learnings (2)
📚 Learning: 2025-10-16T17:24:11.588Z
Learnt from: brimoor
Repo: voxel51/fiftyone PR: 6373
File: docs/source/dataset_zoo/datasets/ucf101.rst:32-0
Timestamp: 2025-10-16T17:24:11.588Z
Learning: In FiftyOne documentation, dataset zoo classes follow the pattern `fiftyone.zoo.datasets.base.{DatasetName}Dataset` and should be referenced using `:class:` directives (e.g., `:class:`UCF101Dataset <fiftyone.zoo.datasets.base.UCF101Dataset>``). This is a valid and established documentation pattern.

Applied to files:

  • docs/source/user_guide/using_datasets.rst
📚 Learning: 2025-11-25T15:39:52.528Z
Learnt from: paularamo
Repo: voxel51/fiftyone PR: 6619
File: docs/source/tutorials/cosmos-transfer-integration.ipynb:812-813
Timestamp: 2025-11-25T15:39:52.528Z
Learning: In the cosmos-transfer-integration.ipynb tutorial for FiftyOne grouped datasets: when computing embeddings for original images and Cosmos-Transfer generated outputs, use separate embedding fields (e.g., "image_embeddings" for original images and "output_last_embeddings" for generated outputs) to enable independent similarity analysis and comparison between the two slice types.

Applied to files:

  • docs/source/user_guide/using_datasets.rst
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: build
🔇 Additional comments (4)
docs/source/_includes/substitutions.rst (1)

72-79: Camera substitutions look consistent and correct

The new |CameraIntrinsics|, |PinholeCameraIntrinsics|, |OpenCVCameraIntrinsics|, |OpenCVFisheyeCameraIntrinsics|, |CameraIntrinsicsRef|, |SensorExtrinsics|, |CameraExtrinsics|, and |CameraProjector| substitutions follow the existing pattern and point to plausible module paths.

docs/source/user_guide/using_datasets.rst (3)

792-873: Dataset-level camera calibration examples are clear and aligned with APIs

The new “Storing camera calibration” section correctly introduces camera_intrinsics and sensor_extrinsics as dataset-level dictionaries, uses realistic keys (e.g., "left", "left::ego"), and shows dataset.save() after edits, consistent with earlier sections on dataset metadata.


5791-5819: Camera intrinsics usage and matrix constructor look sound

The intrinsics section clearly differentiates the intrinsics models and shows both direct construction (OpenCVCameraIntrinsics(...)) and PinholeCameraIntrinsics.from_matrix(K). The example imports numpy before using np.array and demonstrates accessing intrinsic_matrix, which matches the intended API.


5878-6009: Calibration resolution and CameraProjector workflow read correctly

The sections on resolving calibration (resolve_intrinsics, resolve_extrinsics) and on CameraProjector describe a coherent resolution order (sample-level intrinsics, refs, then dataset-level intrinsics keyed by slice) and a realistic AV-style workflow (dataset-level static calibration + sample-level ego pose, then projection/unprojection with depth). The examples are consistent with the earlier dataset-level calibration section.

Please verify against the current Dataset.resolve_intrinsics, Dataset.resolve_extrinsics, and CameraProjector signatures in code to ensure parameter names and default behaviors (e.g., chain_via handling and how sample-level extrinsics like ego_pose are discovered) exactly match the implementation.

@sashankaryal sashankaryal force-pushed the feat/camera-params-rest branch from 02af9fb to 0843f11 Compare January 9, 2026 21:58
Base automatically changed from feat/camera-params-rest to develop January 9, 2026 23:43
|
"""

import logging
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

branch needs updating?

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 2

🤖 Fix all issues with AI agents
In @docs/source/user_guide/using_datasets.rst:
- Around line 792-873: The example for sensor_extrinsics uses dataset without
defining it, causing a NameError; make the snippet self-contained by adding the
necessary import and dataset initialization before assigning
dataset.sensor_extrinsics (e.g., import fiftyone as fo and create or load a
dataset via fo.Dataset() or foz.load_zoo_dataset), then set the
sensor_extrinsics dict with fo.SensorExtrinsics entries and call dataset.save();
keep the existing keys ("left::ego", etc.) and the use of fo.SensorExtrinsics,
camera_intrinsics, and dataset.save() intact.
- Around line 5763-6010: The example uses undefined variables camera_to_ego and
ego_to_world when composing extrinsics; replace or define them: set
camera_to_ego = extrinsics (the already-created fo.SensorExtrinsics) and create
or reference an ego_to_world SensorExtrinsics (e.g., a separate
fo.SensorExtrinsics instance or one resolved from sample/dataset) before calling
compose; then call camera_to_ego.compose(ego_to_world) (or
extrinsics.compose(ego_to_world)) so the composition uses defined
SensorExtrinsics objects.
📜 Review details

Configuration used: Path: .coderabbit.yaml

Review profile: ASSERTIVE

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between 268ffa7 and 621d590.

📒 Files selected for processing (2)
  • docs/source/_includes/substitutions.rst
  • docs/source/user_guide/using_datasets.rst
🧰 Additional context used
🧠 Learnings (2)
📚 Learning: 2025-10-16T17:24:11.588Z
Learnt from: brimoor
Repo: voxel51/fiftyone PR: 6373
File: docs/source/dataset_zoo/datasets/ucf101.rst:32-0
Timestamp: 2025-10-16T17:24:11.588Z
Learning: In FiftyOne documentation, dataset zoo classes follow the pattern `fiftyone.zoo.datasets.base.{DatasetName}Dataset` and should be referenced using `:class:` directives (e.g., `:class:`UCF101Dataset <fiftyone.zoo.datasets.base.UCF101Dataset>``). This is a valid and established documentation pattern.

Applied to files:

  • docs/source/user_guide/using_datasets.rst
📚 Learning: 2025-11-25T15:39:52.528Z
Learnt from: paularamo
Repo: voxel51/fiftyone PR: 6619
File: docs/source/tutorials/cosmos-transfer-integration.ipynb:812-813
Timestamp: 2025-11-25T15:39:52.528Z
Learning: In the cosmos-transfer-integration.ipynb tutorial for FiftyOne grouped datasets: when computing embeddings for original images and Cosmos-Transfer generated outputs, use separate embedding fields (e.g., "image_embeddings" for original images and "output_last_embeddings" for generated outputs) to enable independent similarity analysis and comparison between the two slice types.

Applied to files:

  • docs/source/user_guide/using_datasets.rst
⏰ Context from checks skipped due to timeout of 90000ms. You can increase the timeout in your CodeRabbit configuration to a maximum of 15 minutes (900000ms). (1)
  • GitHub Check: build
🔇 Additional comments (1)
docs/source/_includes/substitutions.rst (1)

72-80: Verify all new fiftyone.core.camera.* substitutions resolve to real symbols (doc build blocker if not).

If any class name/module path differs from the implementation, Sphinx will emit warnings/errors and/or generate broken links. Ensure these eight classes exist in fiftyone.core.camera:

  • CameraIntrinsics
  • PinholeCameraIntrinsics
  • OpenCVCameraIntrinsics
  • OpenCVFisheyeCameraIntrinsics
  • CameraIntrinsicsRef
  • SensorExtrinsics
  • CameraExtrinsics
  • CameraProjector

@sashankaryal sashankaryal merged commit 28ee6ec into develop Jan 12, 2026
12 checks passed
@sashankaryal sashankaryal deleted the docs/camera branch January 12, 2026 21:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants