clinplayer / Point2Skeleton

Point2Skeleton: Learning Skeletal Representations from Point Clouds (CVPR2021)
MIT License
211 stars 38 forks source link

UnicodeDecodeError: 'utf-8' codec can't decode byte 0x91 in position 648: invalid start byte #10

Closed YdSyd closed 2 years ago

YdSyd commented 2 years ago

Hi, Thank you for the awesome work.

I reproduce your work successfully and I want to use it to test my data. My data are human .pcd files, I transform the data to .ply format by using pcl_pcd2ply command. But when I run python test.py, the terminal has the following error: UnicodeDecodeError: 'utf-8' codec can't decode byte 0x91 in position 648: invalid start byte. error information

May I have your suggestions to fix this problem? Any help is much appreciated:)

Best wishes,

YdSyd

clinplayer commented 2 years ago

Hi, I think this is because of the implementation of the PLY loader. I simply assume the input PLY files are in Unicode format with fixed header information while your PLY may be encoded as binary files. You can re-write the function load_ply_points(pc_filepath, expected_point=2000) defined in FileRW.py based on your PLY format. Just make sure this function returns an N*3 NumPy array (N is fixed) that stores xyz point locations.

For your reference, here is a general PLY loader: https://github.com/dranjan/python-plyfile