Skip to content

Conversation

@A-Artemis
Copy link
Contributor

@A-Artemis A-Artemis commented Dec 29, 2025

Summary

Adds an endpoint which displays the available camera devices

How to test

GET /api/system/devices/camera

Checklist

  • The PR title and description are clear and descriptive
  • I have manually tested the changes
  • All changes are covered by automated tests
  • All related issues are linked to this PR (if applicable)
  • Documentation has been updated (if applicable)

@A-Artemis A-Artemis self-assigned this Dec 29, 2025
@A-Artemis A-Artemis requested a review from a team as a code owner December 29, 2025 10:47
Copilot AI review requested due to automatic review settings December 29, 2025 10:47
@github-actions github-actions bot added DEPENDENCY Any changes in any dependencies (new dep or its version) should be produced via Change Request on PM TEST Any changes in tests BUILD Geti Tune Backend Issues related to Geti Tune Studio backend labels Dec 29, 2025
@A-Artemis A-Artemis linked an issue Dec 29, 2025 that may be closed by this pull request
Copy link
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR adds a new endpoint to retrieve available camera devices on the system. The implementation includes a new CameraInfo schema, service method to enumerate cameras, and API endpoint at /api/system/devices/camera.

Key changes:

  • Added get_camera_devices() method to SystemService that uses the cv2-enumerate-cameras library
  • Created new CameraInfo schema with index and name fields
  • Added GET endpoint /api/system/devices/camera to the system router

Reviewed changes

Copilot reviewed 6 out of 7 changed files in this pull request and generated 1 comment.

Show a summary per file
File Description
application/backend/pyproject.toml Added cv2-enumerate-cameras dependency version 1.3.1
application/backend/app/schemas/system.py Defined CameraInfo schema for camera device information
application/backend/app/services/system_service.py Implemented get_camera_devices() method using enumerate_cameras library
application/backend/app/api/routers/system.py Added GET /api/system/devices/camera endpoint
application/backend/tests/unit/services/test_system_service.py Added test coverage for get_camera_devices() method
application/backend/tests/unit/routers/test_system.py Added test coverage for camera devices endpoint

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@github-actions
Copy link

github-actions bot commented Dec 29, 2025

📊 Test coverage report

Metric Coverage
Lines 40.2%
Functions 34.9%
Branches 84.8%
Statements 40.2%

@github-actions
Copy link

github-actions bot commented Dec 29, 2025

Docker Image Sizes

CPU

Image Size
geti-tune-cpu:pr-5101 2.85G
geti-tune-cpu:sha-f17857f 2.85G

GPU

Image Size
geti-tune-gpu:pr-5101 10.61G
geti-tune-gpu:sha-f17857f 10.61G

XPU

Image Size
geti-tune-xpu:pr-5101 8.69G
geti-tune-xpu:sha-f17857f 8.69G

@leoll2 leoll2 added this pull request to the merge queue Dec 30, 2025
Merged via the queue into develop with commit 011a9cc Dec 30, 2025
31 checks passed
@leoll2 leoll2 deleted the aurelien/camera-devices-endpoint branch December 30, 2025 11:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

BUILD DEPENDENCY Any changes in any dependencies (new dep or its version) should be produced via Change Request on PM Geti Tune Backend Issues related to Geti Tune Studio backend TEST Any changes in tests

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add endpoint to return available camera devices

3 participants