当前位置:网站首页>Conversion between pointcloud and numpy arrays in open3d
Conversion between pointcloud and numpy arrays in open3d
2022-06-28 14:34:00 【Jianghu night rain ABC】
open3d In the use of open3d.io.read_point_cloud() After reading point cloud data , The return is pointcloud Data of type , Sometimes I wish I could use numpy Handle point clouds , At this time, the conversion between the two is required ( Strictly speaking, the data is just copied and then transmitted ).
1.pointcloud convert to numpy
import numpy as np
import open3d as o3d
A=[]
pcd=o3d.io.read_point_cloud("/bunny.ply")# The path should be set according to the actual situation
A=np.asarray(pcd.points)#A Has become a n*3 Matrix
print(A)
2.numpy The data in the array is converted into pointcloud
# here B Is already a n*3 Of numpy.ndarray( That is, common array types )
pcd=o3d.geometry.PointCloud()# Instantiate a pointcloud class
pcd.points=o3d.utility.Vector3dVector(B)# Pass in coordinate data to this class , here pcd.points It is already a point cloud
o3d.visualization.draw_geometries([pcd.points])# Show me
边栏推荐
- 力扣解法汇总522-最长特殊序列 II
- Only four breakthrough Lenovo smart Summer Palace in mainland China won the "IDC Asia Pacific Smart City Award in 2022"
- Leetcode (406) - rebuild the queue based on height
- @ControllerAdvice + @ExceptionHandler 全局处理 Controller 层异常
- Opening and closing principle
- open3d里pointcloud和numpy数组之间的转化
- 2022 recurrent training question bank and online simulation examination for safety inspection of metal and nonmetal mines (underground mines)
- [Zhongyi Xinsheng] 5 SPI interface test TF Card
- Tencent cloud international ECS has no network after logging in. How to troubleshoot?
- 仅用递归函数和栈操作逆序一个栈
猜你喜欢

openGauss内核:SQL解析过程分析

Work study management system based on ASP

干货 | 科研人的KPI怎么算,H指数和G指数是什么

2022下半年软考考试时间安排已确定!

字节跳动埋点数据流建设与治理实践
![[Zhongyi Xinsheng] 5 SPI interface test TF Card](/img/d9/56ded362b3055f4f0efc3ce0eec5d5.jpg)
[Zhongyi Xinsheng] 5 SPI interface test TF Card

Open source invites you to participate in openinfra days China 2022. Topic collection is in progress ~

Talking from the little nematode -- tracing the evolution of nervous system and starting life simulation

A bug liver a week I can't help mentioning issue

Can your code talk? (upper)
随机推荐
10 key points to effectively improve performance interview
Youju new material rushes to Shenzhen Stock Exchange: it plans to raise 650million yuan, with an annual revenue of 333million yuan
PC Museum - familiar and strange ignorant age
优巨新材冲刺深交所:拟募资6.5亿 年营收3.33亿
sort
Leetcode (665) -- non decreasing column
MySQL slave error: "you cannot 'alter' a log table“
运行近20年,基于Win 98的火星探测器软件迎来首次升级
Why can't Bert completely kill the BM25??
Numbers that only appear once
腾讯再遭大股东Prosus减持:后者还从京东套现37亿美元
从小小线虫谈起——溯源神经系统进化,开启生命模拟
Jingyuan's safe sprint to the Growth Enterprise Market: it plans to raise 400million yuan for investment and Yunyou software is the shareholder
How to handle the safest account opening with Huatai Securities app
JS judge whether the string is empty or not
Robot range of motion (DFS)
【数字IC精品文章收录】近500篇文章|学习路线|基础知识|接口|总线|脚本语言|芯片求职|安全|EDA|工具|低功耗设计|Verilog|低功耗|STA|设计|验证|FPGA|架构|AMBA|书籍|
哪个证券公司最大最安全 怎么办理开户最安全
Rails advanced -- framework theory cognition and construction scheme construction (I)
Introduction to common components of IOT low code platform