Open3d: Read Point Cloud Function Type Error when specifying format argument.

Created on 7 Jan 2019  路  3Comments  路  Source: intel-isl/Open3D

Describe the bug
The documentation and the source code of this library says that we can specify file format but I only get a TypeError on filename when I do so with the same argument.

To Reproduce

  1. Import library in Jupyter.
  2. Run the following code with a XYZ PC file: x = o3.read_point_cloud(filename='data\\cutView1.txt', format='xyz')
  3. Following error is produced for me:
---------------------------------------------------------------------------
TypeError                                 Traceback (most recent call last)
<ipython-input-49-6a89bc1597c5> in <module>()
----> 1 x = o3.read_point_cloud(filename='data\\cutView1.txt', format='xyz')

TypeError: read_point_cloud(): incompatible function arguments. The following argument types are supported:
    1. (filename: str) -> open3d.win32.64b.open3d.PointCloud

Invoked with: kwargs: filename='data\\cutView1.txt', format='xyz'

Expected behavior
Load the file as it does when I don't specify the format after manually changing the extension of file to .xyz.

Screenshots
NA

Desktop (please complete the following information):

  • OS: Win10
  • Browser Chrome
  • Version 0.3.0
  • Py: 3.5.5

Additional context
Link to PC file: https://pastebin.com/Euv7Ha9J

question

All 3 comments

It is a new feature in Open3D 0.4. You need to upgrade Open3D. Here is what I got on my machine:

Python 3.6.7 |Anaconda custom (64-bit)| (default, Oct 23 2018, 19:16:44) 
[GCC 7.3.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import open3d
>>> print(open3d.__version__)
0.4.0.0
>>> pcd = open3d.read_point_cloud("noisy_stanford_bunny_pc.txt", format="xyz")
>>> print(pcd)
PointCloud with 1660 points.

@qianyizh Thanks for the prompt reply. I'll check out the update. Are there any major bugs or breaking changes in the version that I should be aware of?

Was this page helpful?
0 / 5 - 0 ratings

Related issues

blackccpie picture blackccpie  路  3Comments

DKandrew picture DKandrew  路  3Comments

DKandrew picture DKandrew  路  4Comments

Timu777 picture Timu777  路  3Comments

mike239x picture mike239x  路  3Comments