las2pcd How to convert?
csdyang opened this issue · 2 comments
csdyang commented
las2pcd How to convert?
Xanxus1111 commented
same question
altarizer commented
This method cannot work in this project
https://www.danielgm.net/cc/
install cloudcompare
open cloudcompare
load las file
save as pcd file
So i hope you will use this instread,
Make Converting Python Script
- make requirements.txt
laspy==1.7.1
numpy==1.19.5
pclpy==0.11.0
- install packages
$ pip install -r requirements.txt
- write code in las2pcd.py
import numpy as np
from pclpy import pcl
import pclpy
src_path = "src.las"
desc_path = "dest.pcd"
def las2pcd():
pc = pclpy.io.las.read(src_path, "PointXYZ")
writer = pcl.io.PCDWriter()
writer.writeBinary(desc_path, pc)
las2pcd()
- convert
$ python las2pcd.py