Skip to main content
# pyoni
Pure python tool for manipulating OpenNI recorded files (oni). This tool supports extraction of data, time rescaling and fix of broken files.

Options
=======================
```
usage: pyonitool.py [-h] [--info] [--times] [--seeks] [--dump] [--copy]
[--rescale RESCALE] [--fixcut] [--checkcut]
[--dupframes DUPFRAMES] [--stripcolor] [--stripdepth]
[--stripir] [--registercolor] [--registerdepth] [--mjpeg]
[--extractcolor EXTRACTCOLOR]
[--extractdepth EXTRACTDEPTH] [--extractir EXTRACTIR]
[--fseek FSEEK] [--fduration FDURATION]
[--skipframes SKIPFRAMES] [--coloreddepth]
[--output OUTPUT] [--cutbytime CUTBYTIME]
[--cutbyframe CUTBYFRAME]
file

Scan OpenNI ONI files

positional arguments:
file ONI filename

optional arguments:
-h, --help show this help message and exit
--info
--times print times of each frame
--seeks print seeks
--dump
--copy simply copies the content of the ONI via parsing
(rebuilds the seektable only)
--rescale RESCALE rescale timings
--fixcut fixes cut file NOT TESTED HERE
--checkcut checks if file was cut NOT TESTED HERE
--dupframes DUPFRAMES
duplicate frames
--stripcolor
--stripdepth
--stripir removes IR
--registercolor registers color over depth
--registerdepth registers depth over color
--mjpeg extract the color stream as motion jpeg
--extractcolor EXTRACTCOLOR
extract the color stream single jpeg or png images.
This option specifies the target path, numbering is
the frame number
--extractdepth EXTRACTDEPTH
extract the depth stream single png images. This
option specifies the target path, numbering is the
frame number
--extractir EXTRACTIR
extract the depth stream single png images. This
option specifies the target path, numbering is the
frame number
--fseek FSEEK seek frame for extract
--fduration FDURATION
duration of extraction in frames
--skipframes SKIPFRAMES
skip n frames
--coloreddepth colored depth
--output OUTPUT
--cutbytime CUTBYTIME
cut by specifing time in seconds:
startseconds,endseconds
--cutbyframe CUTBYFRAME
cut by specifing time in frames: startframe,endframe
```

Build
=======================

Two C++ codes require manual steps using cmake and then the resulting shared libraries needs to be visible to python at startup (PATH under Windows, LD_LIBRARY_PATH under Linux, DYLD_LIBRARY_PATH under OSX)

1) make sure that Eigen3 is available http://eigen.tuxfamily.org
2) go top level
3) mkdir build
cd build
cmake ..
4) make
5) make the output DLL/SO visible

In the next version I will package everything

References
=======================

https://github.com/OpenNI/OpenNI2/blob/master/Source/Drivers/OniFile/DataRecords.cpp
https://github.com/OpenNI/OpenNI2/blob/master/Source/Core/OniRecorder.cpp
https://github.com/OpenNI/OpenNI2/blob/master/Source/Core/OniDataRecords.cpp
CODECS: https://github.com/OpenNI/OpenNI2/blob/5b88c95e4f8d19b95713e3c873c7d07e48e5605b/Source/Drivers/OniFile/Formats/Xn16zEmbTablesCodec.h
https://github.com/OpenNI/OpenNI2/blob/5b88c95e4f8d19b95713e3c873c7d07e48e5605b/Source/Drivers/OniFile/Formats/XnStreamCompression.cpp

Metadata

Release files for pyoni 0.6.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for pyoni 0.6.1
File Size Uploaded
pyoni-0.6.1.tar.gz 31.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pyoni 0.6.1
File Interpreter ABI Platform
pyoni-0.6.1.macosx-10.10-intel.tar.gz Details

Total release size: 132.1 kB

Release files / pyoni-0.6.1.tar.gz

Download URL pyoni-0.6.1.tar.gz
Size 31.5 kB
Tags Source
SHA-256 checksum
How to use checksums
6ada1de948e2477d13324ec63604e4cc5ae5d620013b25f44e5aec73a2e71cd6
BLAKE2b-256 checksum
How to use checksums
17f8a1d4025f9437bbd11e8b77f13ec53321459821be28cf1e2480c8b112c84d
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release files / pyoni-0.6.1.macosx-10.10-intel.tar.gz

Download URL pyoni-0.6.1.macosx-10.10-intel.tar.gz
Size 100.6 kB
Tags Source
SHA-256 checksum
How to use checksums
389c7447ab6527d3cea5a698c2c7c511e513bb446ad6a2bf5e43500f8b4c6ce9
BLAKE2b-256 checksum
How to use checksums
df1227513a525919acf888a83c6ba6b83b927dd0edcf59c923fb271f84bb0286
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

This release

0.6.1 This release

2 release files

0.6.0

2 release files

0.5.1

2 release files

0.5

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page