Skip to content

Commit feef041

Browse files
committed
Add README.md in English
Signed-off-by: zz990099 <771647586@qq.com>
1 parent baa433f commit feef041

File tree

2 files changed

+180
-56
lines changed

2 files changed

+180
-56
lines changed

README.md

Lines changed: 58 additions & 56 deletions
Original file line numberDiff line numberDiff line change
@@ -1,26 +1,30 @@
11
# Foundationpose-CPP
22
## About this project
33

4-
该项目基于[nvidia-issac-pose-estimation](https://github.com/NVIDIA-ISAAC-ROS/isaac_ros_pose_estimation)改写,去除了原项目中的复杂依赖,能够使用`FoundationPose`的Python工程[FoundationPose](https://github.com/NVlabs/FoundationPose)导出的onnx模型来做推理,部署应用十分方便。
4+
This project is adapted from [nvidia-issac-pose-estimation](https://github.com/NVIDIA-ISAAC-ROS/isaac_ros_pose_estimation), with simplified dependencies. It enables inference using ONNX models exported from the [Python implementation](https://github.com/NVlabs/FoundationPose) of `FoundationPose`, making deployment and application highly convenient.
55

6-
**Notes:** 该项目只包含了`FoundationPose`部分的代码,实际上6D位姿检测的运行,还依赖于目标物的掩码,需要运行类似`SAM`的算法,[EasyDeploy](https://github.com/zz990099/EasyDeploy)项目下提供了`MobileSAM``NanoSAM`的算法实现和推理优化,可供参考。
6+
***Notes***:​​ This repository only contains the code for the `FoundationPose` component. The complete 6D pose estimation pipeline also relies on object masks, which can be generated by algorithms like `SAM`. For reference implementations and optimized inference of `MobileSAM` and `NanoSAM`, please visit [EasyDeploy](https://github.com/zz990099/EasyDeploy).
77

88
## Update LOG
99

10-
- [2025.04] 解耦`Register``Track`过程; 令算法输出mesh下的位姿,提供mesh_loader相关的接口和方法供外部拓展。
11-
- [2025.03] 渲染过程与原Python工程对齐,支持无texture纹理输入渲染. [对应PR](https://github.com/zz990099/foundationpose_cpp/pull/13).
12-
- [2025.03] 添加对Jetson Orin平台支持,[一键配置docker环境](docs/build_enviroment_on_jetson.md)
10+
**[2025.04]** Decoupled `Register` and `Track` processes; Output poses under mesh coordinates, providing `mesh_loader` interfaces for external extension. Related [PR](https://github.com/zz990099/foundationpose_cpp/pull/21).
11+
12+
**[2025.03]** Aligned rendering process with the original Python implementation, supporting rendering without texture input. Related [PR](https://github.com/zz990099/foundationpose_cpp/pull/13).
13+
14+
**[2025.03]** Added support for Jetson Orin platform with one-click Docker environment setup. See [link](docs/build_enviroment_on_jetson.md).
1315

1416
## Features
1517

16-
1. 去除了原工程的复杂环境构建过程,以及各种依赖项问题,能够轻松适配到其他项目工程中。
17-
2.`FoundationPose`算法本身做了封装,**支持动态尺寸图像输入**,简单灵活。
18-
3. 提供了基于`BundleSDF`生成目标物三维模型的[脚本教程](./docs/gen_3d_obj_with_bundlesdf.md)
19-
4. :fire: 支持Orin开发板(Orin-NX-16GB)
18+
1. Removed complex environment setup and dependency issues from the original project, enabling easy integration with other projects.
19+
20+
2. Implemented encapsulation of the `FoundationPose` algorithm, ​​supporting dynamic-sized image input​​ for flexible usage.
21+
Provided [tutorial scripts](docs/gen_3d_obj_with_bundlesdf.md) for generating 3D object models using BundleSDF.
22+
23+
3. :fire: Supports Jetson Orin development boards (Orin-NX-16GB).
2024

2125
## Demo
2226

23-
运行公开数据`mustard`模型检测结果:
27+
Test results on public mustard dataset:
2428

2529
| <img src="./assets/test_foundationpose_register.png" alt="1" width="500"> |
2630
|:----------------------------------------:|
@@ -30,93 +34,91 @@
3034
|:----------------------------------------:|
3135
| **foundationpose(fp16) Track test result** |
3236

33-
以下是在`nvidia-4060-8G`, `i5-12600kf`硬件上执行结果
37+
**Performance on `nvidia-4060-8G` and `i5-12600kf`:**
3438

3539
| nvidia-4060-8G | fps | cpu | gpu |
3640
|:---------:|:---------:|:----------------:|:----------------:|
3741
| foundationpose(fp16)-Register | 2.8 | 100% | 6.5GB |
3842
| foundationpose(fp16)-Track | 220 | 100% | 5.8GB |
3943

40-
以下是在`jetson-orin-nx-16GB`硬件上执行结果
44+
**Performance on jetson-orin-nx-16GB:**
4145

4246
| jetson-orin-nx-16GB | fps | cpu | mem_total |
4347
|:---------:|:---------:|:----------------:|:----------------:|
4448
| foundationpose(fp16)-Register | 0.6 | 15% | 5.6GB(5.5GB on gpu) |
4549
| foundationpose(fp16)-Track | 100 | 60% | 5.1GB(5.0GB on gpu) |
4650

47-
4851
## Usage
49-
50-
### Enviroment Build
51-
52-
1. 下载`foundationpose_cpp`repo
53-
```bash
54-
git clone git@github.com:zz990099/foundationpose_cpp.git
55-
cd foundationpose_cpp
56-
git submodule init
57-
git submodule update
58-
```
59-
60-
2. 使用`docker`来构建运行环境
61-
```bash
52+
### Environment Setup
53+
54+
1. Clone the repository:
55+
```bash
56+
git clone git@github.com:zz990099/foundationpose_cpp.git
57+
cd foundationpose_cpp
58+
git submodule init
59+
git submodule update
60+
```
61+
62+
2. Build using Docker:
63+
```bash
6264
cd ${foundationpose_cpp}
6365
bash easy_deploy_tool/docker/easy_deploy_startup.sh
64-
# choose `jetson` -> `trt10_u2204`/`trt8_u2204` (`trt8_u2004` will not work)
66+
# Select `jetson` -> `trt10_u2204`/`trt8_u2204` (`trt8_u2004` not supported)
6567
bash easy_deploy_tool/docker/into_docker.sh
66-
```
68+
```
6769

68-
### Convert Models
70+
### Model Conversion
6971

70-
1. [google drive](https://drive.google.com/drive/folders/1AmBopDz-RrykSZVCroDH6jFc1-k8HkL0?usp=drive_link)中下载onnx模型文件,放到`/workspace/models/`文件夹下。
72+
1. Download ONNX models from google drive and place them in `/workspace/models/`.
7173

72-
2. 运行模型转换脚本
73-
```bash
74+
2. Convert models:
75+
```bash
7476
cd /workspace
7577
bash tools/cvt_onnx2trt.bash
76-
```
78+
```
7779

78-
### Compile Code
80+
### Build Project
7981

80-
1. 编译整个工程
81-
```bash
82-
cd /workspace
83-
mkdir build && cd build
84-
cmake -DENABLE_TENSORRT=ON ..
85-
make -j
86-
```
82+
1. Compile the project:
83+
```bash
84+
cd /workspace
85+
mkdir build && cd build
86+
cmake -DENABLE_TENSORRT=ON ..
87+
make -j
88+
```
8789

88-
### Run demo
90+
### Run Demo
8991

90-
#### 运行公开数据集demo ---- mustard
92+
#### Use public Dataset Demo (mustard)
9193

92-
1. 下载数据集,放到`/workspace/test_data/`下,并解压,[下载地址](https://drive.google.com/drive/folders/1pRyFmxYXmAnpku7nGRioZaKrVJtIsroP)
94+
1. Download and extract the dataset to `/workspace/test_data/` from here.
9395

94-
2. 直接运行测试用例即可
95-
```bash
96+
2. Run tests:
97+
```bash
9698
cd /workspace/build
9799
./bin/simple_tests --gtest_filter=foundationpose_test.test
98-
```
100+
```
99101

100-
#### 自制三维模型
102+
### Custom 3D Model Generation
101103

102-
1. 参考[利用BundleSDF生成三维模型](./docs/gen_3d_obj_with_bundlesdf.md)
104+
1. Refer to [Generating 3D Models with BundleSDF](./docs/gen_3d_obj_with_bundlesdf.md).
103105

104-
2. 根据您的自定义数据,修改`/workspace/simple_tests/src/test_foundationpose.cpp`下的路径,重新编译。
106+
2. Modify paths in `/workspace/simple_tests/src/test_foundationpose.cpp` for your data and rebuild.
105107

106-
3. 运行测试用例
107-
```bash
108+
3. Run tests:
109+
```bash
108110
cd /workspace/build
109111
./bin/simple_tests --gtest_filter=foundationpose_test.test
110-
```
112+
```
111113

112-
`/workspace/test_data/`下,可以看到`Register``Track`两个过程的结果。
114+
4. Results for Register and Track processes will be saved in `/workspace/test_data/`.
113115

114116
## References
115117

116-
- [nvidia-issac-pose-estimation](https://github.com/NVIDIA-ISAAC-ROS/isaac_ros_pose_estimation)
118+
- [nvidia-isaac-pose-estimation](https://github.com/NVIDIA-ISAAC-ROS/isaac_ros_pose_estimation)
117119
- [FoundationPose](https://github.com/NVlabs/FoundationPose)
118120
- [BundleSDF](https://github.com/NVlabs/BundleSDF)
119121
- [XMem](https://github.com/hkchengrex/XMem)
120122
- [EasyDeploy](https://github.com/zz990099/EasyDeploy)
121123

122-
有任何问题,欢迎联系`771647586@qq.com`
124+
For any questions, feel free to raise a issue or contact `771647586@qq.com`.

README_cn.md

Lines changed: 122 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,122 @@
1+
# Foundationpose-CPP
2+
## About this project
3+
4+
该项目基于[nvidia-issac-pose-estimation](https://github.com/NVIDIA-ISAAC-ROS/isaac_ros_pose_estimation)改写,去除了原项目中的复杂依赖,能够使用`FoundationPose`的Python工程[FoundationPose](https://github.com/NVlabs/FoundationPose)导出的onnx模型来做推理,部署应用十分方便。
5+
6+
**Notes:** 该项目只包含了`FoundationPose`部分的代码,实际上6D位姿检测的运行,还依赖于目标物的掩码,需要运行类似`SAM`的算法,[EasyDeploy](https://github.com/zz990099/EasyDeploy)项目下提供了`MobileSAM``NanoSAM`的算法实现和推理优化,可供参考。
7+
8+
## Update LOG
9+
10+
- [2025.04] 解耦`Register``Track`过程; 令算法输出mesh下的位姿,提供mesh_loader相关的接口和方法供外部拓展。[对应PR](https://github.com/zz990099/foundationpose_cpp/pull/21)
11+
- [2025.03] 渲染过程与原Python工程对齐,支持无texture纹理输入渲染. [对应PR](https://github.com/zz990099/foundationpose_cpp/pull/13).
12+
- [2025.03] 添加对Jetson Orin平台支持,[一键配置docker环境](docs/build_enviroment_on_jetson.md)
13+
14+
## Features
15+
16+
1. 去除了原工程的复杂环境构建过程,以及各种依赖项问题,能够轻松适配到其他项目工程中。
17+
2.`FoundationPose`算法本身做了封装,**支持动态尺寸图像输入**,简单灵活。
18+
3. 提供了基于`BundleSDF`生成目标物三维模型的[脚本教程](./docs/gen_3d_obj_with_bundlesdf.md)
19+
4. :fire: 支持Orin开发板(Orin-NX-16GB)
20+
21+
## Demo
22+
23+
运行公开数据`mustard`模型检测结果:
24+
25+
| <img src="./assets/test_foundationpose_register.png" alt="1" width="500"> |
26+
|:----------------------------------------:|
27+
| **foundationpose(fp16) Register test result** |
28+
29+
| <img src="./assets/test_foundationpose_track.gif" alt="1" width="500"> |
30+
|:----------------------------------------:|
31+
| **foundationpose(fp16) Track test result** |
32+
33+
以下是在`nvidia-4060-8G`, `i5-12600kf`硬件上执行结果
34+
35+
| nvidia-4060-8G | fps | cpu | gpu |
36+
|:---------:|:---------:|:----------------:|:----------------:|
37+
| foundationpose(fp16)-Register | 2.8 | 100% | 6.5GB |
38+
| foundationpose(fp16)-Track | 220 | 100% | 5.8GB |
39+
40+
以下是在`jetson-orin-nx-16GB`硬件上执行结果
41+
42+
| jetson-orin-nx-16GB | fps | cpu | mem_total |
43+
|:---------:|:---------:|:----------------:|:----------------:|
44+
| foundationpose(fp16)-Register | 0.6 | 15% | 5.6GB(5.5GB on gpu) |
45+
| foundationpose(fp16)-Track | 100 | 60% | 5.1GB(5.0GB on gpu) |
46+
47+
48+
## Usage
49+
50+
### Enviroment Build
51+
52+
1. 下载`foundationpose_cpp`repo
53+
```bash
54+
git clone git@github.com:zz990099/foundationpose_cpp.git
55+
cd foundationpose_cpp
56+
git submodule init
57+
git submodule update
58+
```
59+
60+
2. 使用`docker`来构建运行环境
61+
```bash
62+
cd ${foundationpose_cpp}
63+
bash easy_deploy_tool/docker/easy_deploy_startup.sh
64+
# choose `jetson` -> `trt10_u2204`/`trt8_u2204` (`trt8_u2004` will not work)
65+
bash easy_deploy_tool/docker/into_docker.sh
66+
```
67+
68+
### Convert Models
69+
70+
1.[google drive](https://drive.google.com/drive/folders/1AmBopDz-RrykSZVCroDH6jFc1-k8HkL0?usp=drive_link)中下载onnx模型文件,放到`/workspace/models/`文件夹下。
71+
72+
2. 运行模型转换脚本
73+
```bash
74+
cd /workspace
75+
bash tools/cvt_onnx2trt.bash
76+
```
77+
78+
### Compile Code
79+
80+
1. 编译整个工程
81+
```bash
82+
cd /workspace
83+
mkdir build && cd build
84+
cmake -DENABLE_TENSORRT=ON ..
85+
make -j
86+
```
87+
88+
### Run demo
89+
90+
#### 运行公开数据集demo ---- mustard
91+
92+
1. 下载数据集,放到`/workspace/test_data/`下,并解压,[下载地址](https://drive.google.com/drive/folders/1pRyFmxYXmAnpku7nGRioZaKrVJtIsroP)
93+
94+
2. 直接运行测试用例即可
95+
```bash
96+
cd /workspace/build
97+
./bin/simple_tests --gtest_filter=foundationpose_test.test
98+
```
99+
100+
#### 自制三维模型
101+
102+
1. 参考[利用BundleSDF生成三维模型](./docs/gen_3d_obj_with_bundlesdf.md)
103+
104+
2. 根据您的自定义数据,修改`/workspace/simple_tests/src/test_foundationpose.cpp`下的路径,重新编译。
105+
106+
3. 运行测试用例
107+
```bash
108+
cd /workspace/build
109+
./bin/simple_tests --gtest_filter=foundationpose_test.test
110+
```
111+
112+
`/workspace/test_data/`下,可以看到`Register``Track`两个过程的结果。
113+
114+
## References
115+
116+
- [nvidia-isaac-pose-estimation](https://github.com/NVIDIA-ISAAC-ROS/isaac_ros_pose_estimation)
117+
- [FoundationPose](https://github.com/NVlabs/FoundationPose)
118+
- [BundleSDF](https://github.com/NVlabs/BundleSDF)
119+
- [XMem](https://github.com/hkchengrex/XMem)
120+
- [EasyDeploy](https://github.com/zz990099/EasyDeploy)
121+
122+
有任何问题,欢迎联系`771647586@qq.com`

0 commit comments

Comments
 (0)