update example and build
This commit is contained in:
@@ -1,13 +1,54 @@
|
||||
# orisys API 文档
|
||||
|
||||
本文件提供了 `orisys` 套件的中文文档
|
||||
## 使用方法
|
||||
1. 根据平台和python 版本下载对应的`.whl`文件
|
||||
|
||||
## 准备 Python 开发环境
|
||||
推荐下载 Anaconda,并使用Python 3.10
|
||||
```
|
||||
# 创建并激活虚拟环境
|
||||
conda create -n orisys python=3.10
|
||||
conda activate orisys
|
||||
```
|
||||
## 安装 CUDA Toolkit 和 cuDNN
|
||||
在官方链接下载和安装:https://developer.nvidia.com/cuda/toolkit
|
||||
或
|
||||
在Anaconda环境中安装(例子使用cuda12.9):
|
||||
https://anaconda.org/channels/nvidia/packages/cuda/overview
|
||||
```
|
||||
conda install nvidia/label/cuda-12.9.0::cuda-toolkit nvidia::cudnn
|
||||
```
|
||||
## SDK安装方法
|
||||
1. 根据平台(win / linux)和python (如p38、p39、p310)版本下载对应的`.whl`文件
|
||||
2. 运行pip命令安装:
|
||||
```bash
|
||||
pip install orisys-{version}-{python-version}-none-{os}_amd64.whl
|
||||
pip install orisys-{version}-{python-version}-{python-version}-{os}_amd64.whl
|
||||
```
|
||||
3. 并测试导入:
|
||||
如
|
||||
```bash
|
||||
pip install orisys-0.2.0-cp310-cp310-win_amd64.whl
|
||||
```
|
||||
|
||||
3. **安装 CuPy(根据您的 CUDA 版本选择):**
|
||||
|
||||
**方法 1:使用 extras(推荐)**
|
||||
```bash
|
||||
# 对于 CUDA 12.x
|
||||
pip install orisys[cuda12]
|
||||
|
||||
# 对于 CUDA 13.x
|
||||
pip install orisys[cuda13]
|
||||
```
|
||||
|
||||
**方法 2:手动安装**
|
||||
```bash
|
||||
# 对于 CUDA 12.x
|
||||
pip install cupy-cuda12x>=12.3.0
|
||||
|
||||
# 对于 CUDA 13.x
|
||||
pip install cupy-cuda13x>=13.0.0
|
||||
```
|
||||
|
||||
4. 测试导入:
|
||||
```python
|
||||
import orisys
|
||||
print(orisys.__version__)
|
||||
@@ -21,8 +62,8 @@ print(orisys.__version__)
|
||||
* **isstitch** (`bool`,可选): 是否启用图像拼接,默认为 `True`。
|
||||
* **cuda** (`bool`,可选): 是否使用 GPU cuda 加速,默认为 `False`。
|
||||
* **verbose** (`bool`,可选): 是否输出初始化及运行过程中的详细日志信息,默认为 `False`。
|
||||
* **config_name** (`str`,可选): 内部算法或传感器配置名称,用于加载对应的参数配置,默认为 `prototype`。
|
||||
|
||||
* **config_name** (`str`,可选): 内部算法或传感器配置`json`文件路径,用于加载对应的参数配置,默认为 `prototype`。
|
||||
* **cal_path** (`str`,可选): 复眼拼接校准文件路径,默认为 `./config/cal.npy`。有多个传感器同时运行时建议传感器类创建时建议填写,避免校准文件覆写。在首次运行时程序会在找不到文件时自动创建。
|
||||
|
||||
### 返回
|
||||
* `Sensor` 实例,用于后续图像采集、形变计算和数据读取操作。
|
||||
|
||||
Reference in New Issue
Block a user