File: integrate_scene.rst

package info (click to toggle)
open3d 0.19.0-5
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 83,496 kB
  • sloc: cpp: 206,543; python: 27,254; ansic: 8,356; javascript: 1,883; sh: 1,527; makefile: 259; xml: 69
file content (55 lines) | stat: -rw-r--r-- 2,225 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
.. _reconstruction_system_integrate_scene:

Integrate scene
-------------------------------------

The final step of the system is to integrate all RGBD images into a single TSDF
volume and extract a mesh as the result.

Input arguments
``````````````````````````````````````

The script runs with ``python run_system.py [config] --integrate``. In
``[config]``, ``["path_dataset"]`` should have subfolders *image* and *depth*
in which frames are synchronized and aligned. In ``[config]``, the optional
argument ``["path_intrinsic"]`` specifies path to a json file that has a camera
intrinsic matrix (See :ref:`/tutorial/pipelines/rgbd_odometry.ipynb#read-camera-intrinsic` for
details). If it is not given, the PrimeSense factory setting is used instead.

Integrate RGBD frames
``````````````````````````````````````

.. literalinclude:: ../../../examples/python/reconstruction_system/integrate_scene.py
   :language: python
   :pyobject: scalable_integrate_rgb_frames
   :end-at:        o3d.visualization.draw_geometries([mesh])
   :linenos:
   :lineno-match:

This function first reads the alignment results from both
:ref:`reconstruction_system_make_fragments` and
:ref:`reconstruction_system_register_fragments`, then computes the pose of each
RGBD image in the global space. After that, RGBD images are integrated using
:ref:`/tutorial/pipelines/rgbd_integration.ipynb`.

Results
``````````````````````````````````````
This is a printed log from the volume integration script.

.. code-block:: sh

    Fragment 000 / 013 :: integrate rgbd frame 0 (1 of 100).
    Fragment 000 / 013 :: integrate rgbd frame 1 (2 of 100).
    Fragment 000 / 013 :: integrate rgbd frame 2 (3 of 100).
    Fragment 000 / 013 :: integrate rgbd frame 3 (4 of 100).
    :
    Fragment 013 / 013 :: integrate rgbd frame 1360 (61 of 64).
    Fragment 013 / 013 :: integrate rgbd frame 1361 (62 of 64).
    Fragment 013 / 013 :: integrate rgbd frame 1362 (63 of 64).
    Fragment 013 / 013 :: integrate rgbd frame 1363 (64 of 64).
    Writing PLY: [========================================] 100%

The following image shows the final scene reconstruction.

.. image:: ../../_static/reconstruction_system/integrate_scene/scene.png
    :width: 500px