shiqiyu / strawberryrobot Goto Github PK
View Code? Open in Web Editor NEWLicense: BSD 3-Clause "New" or "Revised" License
License: BSD 3-Clause "New" or "Revised" License
opencv-python version: 4.8.1.78
Operating System Ubuntu 22.04 (armv8, x86)
Python version: 3.11.5
Camera model: Orbbec Gemini2 (Error reporting), Orbbec Femto W
When I connect my computer to Gemini2 and run the following code https://github.com/opencv/opencv/blob/4.x/samples/python/videocapture_obsensor.py, it reports an error as follows
global obsensor_stream_channel_v4l2.cpp:82 xioctl ioctl: fd=3, req=-1072663263
[ WARN:[email protected]] global obsensor_stream_channel_v4l2.cpp:343 getXu ioctl error return: 110
Fail to grab data from the camera.
Fail to grab data from the camera....
When I switch Gemini2 to Femto W, the demo mentioned above can collect images normally.
When I use the SDK provided by Orbbec, Gemini2 can also collect images normally.
import numpy as np
import cv2 as cv
import sys
def main():
# Open Orbbec depth sensor
orbbec_cap = cv.VideoCapture(0, cv.CAP_OBSENSOR)
if orbbec_cap.isOpened() == False:
sys.exit("Fail to open camera.")
while True:
# Grab data from the camera
if orbbec_cap.grab():
# RGB data
ret_bgr, bgr_image = orbbec_cap.retrieve(None, cv.CAP_OBSENSOR_BGR_IMAGE)
if ret_bgr:
cv.imshow("BGR", bgr_image)
# depth data
ret_depth, depth_map = orbbec_cap.retrieve(None, cv.CAP_OBSENSOR_DEPTH_MAP)
if ret_depth:
color_depth_map = cv.normalize(depth_map, None, 0, 255, cv.NORM_MINMAX, cv.CV_8UC1)
color_depth_map = cv.applyColorMap(color_depth_map, cv.COLORMAP_JET)
cv.imshow("DEPTH", color_depth_map)
else:
print("Fail to grab data from the camera.")
if cv.pollKey() >= 0:
break
orbbec_cap.release()
if __name__ == '__main__':
main()
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.