English | 简体中文
Introduction
Data is the cornerstone of artificial intelligence. The efficiency of data acquisition, exchange, and application directly impacts the advances in technologies and applications. Over the long history of AI, a vast quantity of data sets have been developed and distributed. However, these datasets are defined in very different forms, which incurs significant overhead when it comes to exchange, integration, and utilization -- it is often the case that one needs to develop a new customized tool or script in order to incorporate a new dataset into a workflow.
To overcome such difficulties, we develop Data Set Description Language (DSDL).
Major features
The design of DSDL is driven by three goals, namely generic, portable, extensible. We refer to these three goals together as GPE.
-
Generic
This language aims to provide a unified representation standard for data in multiple fields of artificial intelligence, rather than being designed for a single field or task. It should be able to express data sets with different modalities and structures in a consistent format.
-
Portable
Write once, distribute everywhere. Dataset descriptions can be widely distributed and exchanged, and used in different environments without modification of the source files. The achievement of this goal is crucial for creating an open and thriving ecosystem. To this end, we need to carefully examine the details of the design, and remove unnecessary dependencies on specific assumptions about the underlying facilities or organizations.
-
Extensible
One should be able to extend the boundary of expression without modifying the core standard. For a programming language such as C++ or Python, its application boundaries can be significantly extended by libraries or packages, while the core language remains stable over a long period. Such libraries and packages form a rich ecosystem, making the language stay alive for a very long time.
Installation
Case a install it with pip
pip install dsdl
Case b install it from source
git clone https://github.com/opendatalab/dsdl.git
cd dsdl
python setup.py install
Get Started
Use dsdl parser to deserialize the Yaml file to Python code
dsdl parse --yaml demo/coco_demo.yaml
Modify the configuration & set the directory of media in dataset
Create a configuration file config.py with the following contents(for now dsdl only reading from aliyun oss or local is supported):
local = dict(
type="LocalFileReader",
working_dir="local path of your media",
)
ali_oss = dict(
type="AliOSSFileReader",
access_key_secret="your secret key of aliyun oss",
endpoint="your endpoint of aliyun oss",
access_key_id="your access key of aliyun oss",
bucket_name="your bucket name of aliyun oss",
working_dir="the relative path of your media dir in the bucket")
In config.py, the configuration of how to read the media in a dataset is defined. One should specify the arguments depending on from where to read the media:
- read from local:
working_dirfield inlocalshould be specified (the directory of local media) - read from aliyun oss: all the field in
ali_ossshould be specified (includingaccess_key_secret,endpoint,access_key_id,bucket_name,working_dir)
Visualize samples
dsdl view -y <yaml-name>.yaml -c <config.py> -l ali-oss -n 10 -r -v -f Label BBox Attributes
The description of each argument is shown below:
| simplified argument | argument | description |
|---|---|---|
| -y | --yaml |
The path of dsdl yaml file. |
| -c | --config |
The path of location configuration file. |
| -l | --location |
local or ali-oss,which means read media from local or aliyun oss. |
| -n | --num |
The number of samples to be visualized. |
| -r | --random |
Whether to load the samples in a random order. |
| -v | --visualize |
Whether to visualize the samples or just print the information in console. |
| -f | --field |
The field type to visualize, e.g. -f BBoxmeans show the bounding box in samples, -f Attributesmeans show the attributes of a sample in the console . One can specify multiple field types simultaneously, such as -f Label BBox Attributes. |
| -t | --task |
The task you are working on, for example, -t detection is equivalent to -f Label BBox Polygon Attributes. |
Citation
If you find this project useful in your research, please consider cite:
@misc{dsdl2022,
title={{DSDL}: Data Set Description Language},
author={DSDL Contributors},
howpublished = {\url{https://github.com/opendatalab/dsdl}},
year={2022}
}
License
DSDL is released under the Apache 2.0 license.
Acknowledgement
- Field & Model Design inspired by Django ORM and jsonmodels
Metadata
Release files for odl-cli 0.1.1.post223
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| odl_cli-0.1.1.post223.tar.gz | 150.7 kB | Without provenance | Details for odl_cli-0.1.1.post223.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| odl_cli-0.1.1.post223-py3-none-any.whl | Python 3 | none | any | Details for odl_cli-0.1.1.post223-py3-none-any.whl |
Total release size: 356.5 kB
Release files / odl_cli-0.1.1.post223.tar.gz
| Download URL | odl_cli-0.1.1.post223.tar.gz |
|---|---|
| Size | 150.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
6de94c4809301ee0e1fb7ab8add1f91ad38db6deefaf13d62e9aeb39766bbea7
|
|
BLAKE2b-256 checksum How to use checksums |
03d5898b3b22557f190d6519c16df5363aee279f2ead396580948cc08e8d45ed
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.1 CPython/3.11.1
|
Release files / odl_cli-0.1.1.post223-py3-none-any.whl
| Download URL | odl_cli-0.1.1.post223-py3-none-any.whl |
|---|---|
| Size | 205.8 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
b57bdd20f3fb57f8e047831939aa4788f75e21aa6fce8918ebf470b0600adc43
|
|
BLAKE2b-256 checksum How to use checksums |
dc7e2566cb6874b889563301ba65e4d05aeeb57a5b55adbdb436f8e819686fc2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/4.0.1 CPython/3.11.1
|
Security for odl-cli 0.1.1.post223
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.