Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 4 additions & 2 deletions src/viam/services/vision/vision.py
Original file line number Diff line number Diff line change
Expand Up @@ -168,7 +168,8 @@ async def get_detections(
my_detector = VisionClient.from_robot(robot=machine, "my_detector")

# Get an image from the camera
img = await my_camera.get_image()
images, _ = await my_camera.get_images()
img = images[0]

# Get detections for that image
detections = await my_detector.get_detections(img)
Expand Down Expand Up @@ -235,7 +236,8 @@ async def get_classifications(
my_classifier = VisionClient.from_robot(robot=machine, "my_classifier")

# Get an image from the camera
img = await my_camera.get_image()
images, _ = await my_camera.get_images()
img = images[0]

# Get the 2 classifications with the highest confidence scores for the image
classifications = await my_classifier.get_classifications(img, 2)
Expand Down
Loading