1.切记不要安装最新的python否则无法使用open3D ,官网显示只支持python3.8-3.11
这是我安装的python版本
2.由于访问github很慢,所以我手动下载ply文件
https://github.com/isl-org/open3d_downloads/releases/download/20220201-data/fragment.ply
3.使用vscode编写代码
import open3d as o3d;
import numpy as np;
print('123456abcde')
print("Load a ply point cloud, print it, and render it")
# ply_point_cloud = o3d.data.PLYPointCloud()
# pcd = o3d.io.read_point_cloud(ply_point_cloud.path)
pcd = o3d.io.read_point_cloud("fragment.ply")
print(pcd)
print(np.asarray(pcd.points))
o3d.visualization.draw_geometries([pcd],
zoom=0.3412,
front=[0.4257, -0.2125, -0.8795],
lookat=[2.6172, 2.0475, 1.532],
up=[-0.0694, -0.9768, 0.2024])
点击运行