Python SDK for DSDL
Project description
# DSDL-SDK 使用说明
## 1. 安装DSDL
python 环境3.8及以上 `bash python setup.py install `
## 2. Demo演示(COCO数据集可视化)
#### 2.1 解析器反序列化Yaml为Python代码 `bash dsdl parse --yaml demo/coco_demo.yaml `
#### 2.2 配置文件修改,设置读取路径
在`config.py`中,列举了所有支持的媒体文件读取方式,根据实际情况选择并配置文件路径等信息: a.本地读取: local_config`中的参数`working_dir`(本地数据所在的目录) b.阿里云OSS读取: `ali_oss_kwargs`中的参数(阿里云OSS的配置`access_key_secret, endpoint, access_key_id;桶名称`bucket_name`,数据在桶中的目录`working_dir`)
#### 2.3 可视化功能展示:
`bash python visualize.py -y <yaml-name>.yaml -c ali-oss -n 10 -r -v -f label bbox bool `
每个参数的意义为:
参数简写 | 参数全写 | 参数解释 |——– | ————- | :———————————————————– |-y | –yaml | dsdl_yaml文件的路径 |-c | –config | 只可以指定为`local`或是`ali-oss`,分别表示读取本地的数据与读取阿里云的数据 |-n | –num | 加载数据集的样本数量 |-r | –random | 在加载数据集中的样本时是否随机选取样本,如果不指定的话就按顺序从开始选取样本 |-v | –visualize | 是否将加载的数据进行可视化展示 |-f | –field | 选择需要进行可视化的字段,如`-f bbox`表示可视化bbox,-f label`表示对label进行可视化等等,可以同时选择多个,如-f label bbox bool` |
## Acknowledgments
Field & Model Design inspired by [Django ORM](https://www.djangoproject.com/) and [jsonmodels](https://github.com/jazzband/jsonmodels)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file dsdl-0.1.1.tar.gz
.
File metadata
- Download URL: dsdl-0.1.1.tar.gz
- Upload date:
- Size: 22.9 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.7.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | bd4104fe56300faa0acfdc9823d06958ab955023c4c69d04d4b738bfe597acef |
|
MD5 | 7cfcb5873a6dd905724387fc41881709 |
|
BLAKE2b-256 | 5d7179d0eca9804e5a2ed24982d2778e691f2c83e7fae8dd713930eee9691003 |
File details
Details for the file dsdl-0.1.1-py3-none-any.whl
.
File metadata
- Download URL: dsdl-0.1.1-py3-none-any.whl
- Upload date:
- Size: 31.5 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/4.0.1 CPython/3.7.0
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | e5eb5b6a572983562c608e420e8f472a8d808d63110a3f5c1a508c4f5bc2e178 |
|
MD5 | 8df33cf90178fde8e40a9bc348121fa7 |
|
BLAKE2b-256 | f76c45e67ed26df03aacd5e5fc4428d4d11ffe8f9c8b8295dc8b7a1598acc947 |