Skip to content

jrterven/KinZ-Matlab

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

20 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

KinZ for Matlab, A library for Azure Kinect

At the time of this writing, there are no official Matlab bindings for Azure Kinect.
This library allows using Azure Kinect directly in Matlab.

Installation:

  1. Install the Azure Kinect SDK as described here where it says Microsoft installer. For Windows, Download the .exe and follow the steps. For Ubuntu use the sudo apt install commands shown in the same page.
  2. For Body tracking functionality (optional) you need an NVIDIA GPU and install CUDA. Download from here.
  3. For Body tracking, install the Azure Kinect Body Tracking SDK. For Windows, download the msi installer from here. For Ubuntu simply run the sudo apt install command provided in the webpage.
  4. Before compiling the code for Matlab, make sure the Kinect works correctly using the viewers provided my Microsoft, e.g. C:\Program Files\Azure Kinect SDK v1.4.1\tools\k4aviewer.exe and C:\Program Files\Azure Kinect Body Tracking SDK\tools\k4abt_simple_3d_viewer.exe. In Linux just type k4aviewer or k4abt_simple_3d_viewer in the terminal.
  5. Once the Kinect is correctly installed, close the viewer, and open Matlab.
  6. In Matlab, set the compiler for C++ as shown here.
  7. Open the compile_for_windows.m or compile_for_linux.m, set the corresponding paths and run. If the compilation was successful,
  8. For the case of Windows, add to the windows path environmental variable the bin directory containing the k4a.dll and optionally k4abt.dll (if compiling the body tracking SDK). For example add C:\Program Files\Azure Kinect SDK v1.4.1\tools to the path environmental variable. Follow the instructions described here.

Demos

Inside demos directory, you'll find demos showing all the features of the library.
Currently, there are only 5 demos:

  • videoDemo: shows how to get color, depth IR, and IMU sensors.
  • calibrationDemo: shows how to extract camera calibration values.
  • pointcloudDemos: shows how to get the colored pointcloud and visualize it.
  • bodyTrackingDemo: shows how to get body tracking information and visualize it.

View KinZ-Matlab on File Exchange

RGB, Depth, and Infrared

Coming soon ...

Hand pose estimation

Color image keypoints alt text

Depth image keypoints alt text

For more details checkout the wiki pages.

Citation

@article{terven_cordova_kinz,  
title = {KinZ an azure kinect toolkit for Python and Matlab},  
journal = {Science of Computer Programming},  
pages = {102702},  
year = {2021},  
author = {Juan R. Terven and Diana M. Córdova-Esparza},  
keywords = {Azure Kinect, Python, Matlab}}

Link to paper