Outils pour utilisateurs

Outils du site


intel_realsense

Différences

Ci-dessous, les différences entre deux révisions de la page.

Lien vers cette vue comparative

Prochaine révision
Révision précédente
intel_realsense [2021/03/10 17:25] – créée sergeintel_realsense [2022/03/22 14:12] (Version actuelle) – [Les pages sur la détection de squelette] Benjamin Labomedia
Ligne 1: Ligne 1:
-====== Intel Realsense ======+====== Intel Realsense====== 
 +<WRAP center round box 80% centeralign> 
 +**{{tagpage>skeleton camera3D|Les pages sur les caméras 3D et la détection de squelette}}**     **[[http://translate.google.com/translate?hl=&sl=auto&tl=en&u=https%3A%2F%2Fressources.labomedia.org%2Fintel_realsense|English Version]]** 
 +</WRAP>
  
 +{{ :media_15:img_0005.jpg?600 |}}
 +===== Ressources =====
  
 +  * **[[cameras_de_profondeur|Camera Realsense Installation]] Intel® RealSense™ Computer Vision - Depth and Tracking cameras**
 +
 +  * [[https://intelrealsense.github.io/librealsense/python_docs/_generated/pyrealsense2.html|API python]]
 +  * [[https://pyrealsense.readthedocs.io/en/master/pyrealsense.html|pyrealsense.readthedocs.io]]
 +  * [[https://github.com/IntelRealSense/librealsense/tree/development/wrappers/python/examples| Exemples python sur GitHub]]
 +
 +=====Installation du driver du Capteur D455=====
 +  * **[[https://github.com/IntelRealSense/librealsense/blob/master/doc/distribution_linux.md|github.com librealsense doc linux]]**
 +
 +Validé sur Debian 11 Bullseye
 +
 +<code bash>
 +sudo apt-key adv --keyserver keys.gnupg.net --recv-key F6E65AC044F831AC80A06380C8B3A55A6F3EFCDE || sudo apt-key adv --keyserver hkp://keyserver.ubuntu.com:80 --recv-key F6E65AC044F831AC80A06380C8B3A55A6F3EFCDE
 +sudo apt install software-properties-common
 +sudo add-apt-repository "deb https://librealsense.intel.com/Debian/apt-repo focal main" -u
 +</code>
 +
 +Puis\\
 +  sudo apt update
 +  sudo apt install -f librealsense2-dkms
 +
 +Tester avec:
 +  sudo apt install librealsense2-utils
 +  realsense-viewer
 +  
 +Voir si le module est bien chargé
 +  modinfo uvcvideo | grep "version:"            devrait inclure realsense
 +
 +{{ ::realsense_viewer.png?400 |}}
 +
 +===== Récupération des images avec OpenCV en python =====
 +====Installation de pyrealsense2====
 +  * https://github.com/IntelRealSense/librealsense/tree/master/wrappers/python#installation
 +
 +  python3 -m pip install pyrealsense2 --user
 +
 +====L'exemple de la doc librealsense====
 +  * [[https://github.com/IntelRealSense/librealsense/blob/master/wrappers/python/examples/opencv_viewer_example.py|opencv_viewer_example.py]]
 +
 +{{ :media_14:realsense_opencv.png?800 |}}
 +
 +====Calibration de la caméra====
 +**Avec une calibration, la détction du squelette est beaucoup plus stable.**\\
 +Une copie du script de la doc se trouve dans le dossier rs-imu-calibration: [[https://github.com/sergeLabo/rs-opencv/blob/main/rs-imu-calibration/rs-imu-calibration.py|rs-imu-calibration.py]]\\
 +Suivre le script et le PDF [[https://github.com/sergeLabo/rs-opencv/blob/main/rs-imu-calibration/IMU_Calibration_Tool_for_Intel_RealSense-Depth_Cameras_Whitepaper.pdf|IMU_Calibration_Tool_for_Intel_RealSense-Depth_Cameras_Whitepaper.pdf]]
 +
 +Exemple d'une calibration
 +<code bash>
 +python3 rs-imu-calibration.py
 +waiting for realsense device...
 +  Device PID:  0B5C
 +  Device name:  Intel RealSense D455
 +  Serial number:  053422251581
 +  Product Line:  D400
 +  Firmware version:  05.12.11.00
 +Start interactive mode:
 +FOUND ACCEL with fps=63
 +FOUND GYRO with fps=200
 +-------------------------
 +*** Press ESC to Quit ***
 +-------------------------
 +
 +Align to direction:  [ 0. -1.  0.]   Mounting screw pointing down, device facing out
 + Status.collect_data[...................]]                                                
 +
 +Direction data collected.
 +Align to direction:  [1. 0. 0.]   Mounting screw pointing left, device facing out
 + Status.collect_dataWARNING: MOVING     ]]                                                
 + Status.collect_data[...................]]                                                
 +
 +Direction data collected.
 +Align to direction:  [0. 1. 0.]   Mounting screw pointing up, device facing out
 + Status.collect_data[...................]]                                                
 +
 +Direction data collected.
 +Align to direction:  [-1.  0.  0.]   Mounting screw pointing right, device facing out
 + Status.collect_dataWARNING: MOVING     ]]                                                
 + Status.collect_data[...................]]                                                
 +
 +Direction data collected.
 +Align to direction:  [ 0.  0. -1.]   Viewing direction facing down
 + Status.collect_data[...................]]                                                
 +
 +Direction data collected.
 +Align to direction:  [0. 0. 1.]   Viewing direction facing up
 + Status.collect_dataWARNING: MOVING     ]]                                                
 + Status.collect_data[...................]]                                                
 +
 +Direction data collected.
 +Would you like to save the raw data? Enter footer for saving files (accel_<footer>.txt and gyro_<footer>.txt)
 +Enter nothing to not save raw data to disk. >toto
 +
 +
 +Writing files:
 +accel_toto.txt
 +gyro_toto.txt
 +[ 5.22060069e-04  6.86921142e-05 -2.07340278e-03]
 +[1000 1000 1000 1000 1000 1000]
 +using 6000 measurements.
 +[[ 1.01076975e+00  3.60727590e-02 -8.35014969e-03]
 + [ 4.92538947e-04  1.01871131e+00 -8.72837958e-03]
 + [-6.46373829e-03  1.24138802e-02  1.01959596e+00]
 + [ 2.24575082e-01  1.56413994e-01  2.86333600e-01]]
 +residuals: [  7.25572588   3.70199967 114.63373591]
 +rank: 4
 +singular: [441.23030094 430.20638248 424.20085017  77.26445512]
 +norm (raw data  ): 9.655707
 +norm (fixed data): 9.805557 A good calibration will be near 9.806650
 +Would you like to write the results to the camera? (Y/N)Y
 +Writing calibration to device.
 +  Device PID:  0B5C
 +  Device name:  Intel RealSense D455
 +  Serial number:  053422251581
 +  Firmware version:  05.12.11.00
 +SUCCESS: saved calibration to camera.
 +Done.
 +</code>
 +=====Les pages sur la détection de squelette=====
 +  * [[skeleton_tracking_de_cubemos_logiciel_proprietaire|]]
 +  * [[pose_estimation_avec_opencv]]
 +
 +
 +{{tag> capteurs opencv python realsense sb skeleton camera3D ia}}
intel_realsense.1615397144.txt.gz · Dernière modification : 2021/03/10 17:25 de serge