Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Azure Kinect Examples do not work #1422

Closed
Prakash19921206 opened this issue Dec 31, 2019 · 5 comments
Closed

Azure Kinect Examples do not work #1422

Prakash19921206 opened this issue Dec 31, 2019 · 5 comments
Labels
sensor Support for Azure Kinect, Intel RealSense, etc.

Comments

@Prakash19921206
Copy link

Describe the bug
Python Examples do not execute. I have copied Azure Kinect SDK v1.2.0 to C:/Program Files/
Microsoft Azure Kinect Examples work

To Reproduce
Steps to reproduce the behavior:

  1. clone the repository [open3d 0.9]
  2. go to Open3d/examples/Python/ReconstructionSystem/sensors
  3. py azure_kinect_mkv_reader.py --input "C:/Program Files/Azure Kinect SDK v1.2.0/tools/720.mkv"

Expected behavior
play the video/ record video/open kinect viewer

Environment (please complete the following information):

  • OS: Windows 10 64bit
  • Python version: 3.6.3
  • Open3D version: 0.9
  • Is this remote workstation?: no
  • How did you install Open3D?: pip3

Additional context
output for azure_kinect_mkv_reader.py

No output path, only play mkv
Traceback (most recent call last):
File "D:/Git_Projects/Open3D/examples/Python/ReconstructionSystem/sensors/azure_kinect_mkv_reader.py", line 125, in
reader = ReaderWithCallback(args.input, args.output)
File "D:/Git_Projects/Open3D/examples/Python/ReconstructionSystem/sensors/azure_kinect_mkv_reader.py", line 21, in init
self.reader.open(self.input)
RuntimeError: [Open3D ERROR] Cannot load k4arecord.dll

Process finished with exit code 1

output for azure_kinect_viewer.py

[Open3D INFO] AzureKinectSensor::Connect
[Open3D INFO] sensor_index 0
[Open3D INFO] Serial number: 001075192912
[Open3D INFO] Firmware build: Rel
[Open3D INFO] > Color: 1.6.98
[Open3D INFO] > Depth: 1.6.70[6109.7]
Sensor initialized. Press [ESC] to exit.
Traceback (most recent call last):
File "D:/Git_Projects/Open3D/examples/Python/ReconstructionSystem/sensors/azure_kinect_viewer.py", line 72, in
v.run()
File "D:/Git_Projects/Open3D/examples/Python/ReconstructionSystem/sensors/azure_kinect_viewer.py", line 36, in run
vis.update_geometry()
TypeError: update_geometry(): incompatible function arguments. The following argument types are supported:
1. (self: open3d.open3d.visualization.Visualizer, arg0: open3d.open3d.geometry.Geometry) -> bool

Invoked with: VisualizerWithKeyCallback with name viewer

output for azure_kinect_recorder.py

Prepare writing to 2019-12-31-18-54-38.mkv
[Open3D INFO] AzureKinectSensor::Connect
[Open3D INFO] sensor_index 0
[Open3D INFO] Serial number: 001075192912
[Open3D INFO] Firmware build: Rel
[Open3D INFO] > Color: 1.6.98
[Open3D INFO] > Depth: 1.6.70[6109.7]
Recorder initialized. Press [SPACE] to start. Press [ESC] to save and exit.
Traceback (most recent call last):
File "D:/Git_Projects/Open3D/examples/Python/ReconstructionSystem/sensors/azure_kinect_recorder.py", line 118, in
r.run()
File "D:/Git_Projects/Open3D/examples/Python/ReconstructionSystem/sensors/azure_kinect_recorder.py", line 71, in run
vis.update_geometry()
TypeError: update_geometry(): incompatible function arguments. The following argument types are supported:
1. (self: open3d.open3d.visualization.Visualizer, arg0: open3d.open3d.geometry.Geometry) -> bool

Invoked with: VisualizerWithKeyCallback with name recorder

Process finished with exit code 1

Is there prebuilt c++ open3d libraries? or for now we have to build from source?

Thanks & Regards
Prakash

@theNded
Copy link
Contributor

theNded commented Dec 31, 2019

This specific problem is due to an update of the API.
A quick fix is to change this line to vis.update_geometry([rgbd])

@Prakash19921206 Prakash19921206 changed the title Examples do not work Azure Kinect Examples do not work Jan 1, 2020
@Prakash19921206
Copy link
Author

Prakash19921206 commented Jan 1, 2020

Ok Thanks
After replacing with vis.update_geometry(rgbd)
azure_kinect_viewer.py and azure_kinect_recorder.py examples worked.
but azure_kinect_mkv_reader.py is still not working below is the output

No output path, only play mkv
Traceback (most recent call last):
File "D:/Git_Projects/Open3D/examples/Python/ReconstructionSystem/sensors/azure_kinect_mkv_reader.py", line 125, in
reader = ReaderWithCallback(args.input, args.output)
File "D:/Git_Projects/Open3D/examples/Python/ReconstructionSystem/sensors/azure_kinect_mkv_reader.py", line 21, in init
self.reader.open(self.input)
RuntimeError: [Open3D ERROR] Cannot load k4arecord.dll

i have installed azure kinect SDK 1.2 and 1.3 in C:/Program Files/
also i have added dll files folder path in Environment Variable Path

Update: I noticed same error mentioned here and here

@Me817
Copy link

Me817 commented Jun 5, 2020

I use Open3D 0.10.0, Windows 10 and Azure Kinect SDK v1.2.0. I had the same error but after uninstall and reinstall the Azure Kinect SDK v1.2.0 and add the path C:\Program Files\Azure Kinect SDK v1.2.0\sdk\windows-desktop\amd64\release\bin to PATH in the environment variables and added the K4A_LIB_DIR = C:\Program Files\Azure Kinect SDK v1.2.0\sdk\windows-desktop\amd64\release\bin to the system variables it works perfectly for me
Path for Azure Kinect SDK
.

@yxlao yxlao added the sensor Support for Azure Kinect, Intel RealSense, etc. label Nov 20, 2020
@yxlao
Copy link
Collaborator

yxlao commented Dec 9, 2020

On Windows, the Open3D Kinect plugin will look for the Kinect K4A library located in the default installation paths:

https://github.com/intel-isl/Open3D/blob/3c6e66419a0f5669b27503f1e30dd4960b1aa4ba/cpp/open3d/io/sensor/azure_kinect/K4aPlugin.cpp#L76-L79

Currently, it supports 1.2.0 to 1.4.1. If the K4A library is not in the default location, you'll need to set the K4A_LIB_DIR environment variable to point to the directory containing the K4A's *.dll files.

@yxlao yxlao closed this as completed Dec 9, 2020
@Benjamin-Siebold
Copy link

Benjamin-Siebold commented Apr 23, 2021

I am still having this issue... System Variables set correctly, the reader runs perfectly when running from my base directory

C:\Users\bsieb

but as soon as I add an additional level to my directory it fails...

ex: C:\Users\bsieb\Desktop

image

image

I have tried everything possible... moving all of the files to the script directory, installing open3d with global options... nothing works unless it lives in my base user directory... any help would be appreciated, I would love to be able to wrap this into a exe for other team members if it would work.

UPDATE:

this is in a python environment:

python ( I've tried 3.7.7,3.7.8, and 3.8.5)
o3d (I've tried 0.10.0.0. and 0.12.0.0)
Windows 10

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
sensor Support for Azure Kinect, Intel RealSense, etc.
Projects
None yet
Development

No branches or pull requests

5 participants