This topic describes how to manage the Leeds Sports Pose Dataset, which is a dataset with reference/label_format:Keypoints2D
label(Fig. %s <example-leedssportspose>
).
An reference/glossary:accesskey
is needed to authenticate identity when using TensorBay.
../../../docs/code/LeedsSportsPose.py
../../../docs/code/LeedsSportsPose.py
It takes the following steps to organize the "Leeds Sports Pose" dataset by the ~tensorbay.dataset.dataset.Dataset
instance.
A reference/dataset_structure:catalog
contains all label information of one dataset, which is typically stored in a json file.
../../../tensorbay/opendataset/LeedsSportsPose/catalog.json
The only annotation type for "Leeds Sports Pose" is reference/label_format:Keypoints2D
.
Important
See catalog table <reference/dataset_structure:catalog>
for more catalogs with different label types.
A reference/glossary:dataloader
is needed to organize the dataset into a ~tensorbay.dataset.dataset.Dataset
instance.
../../../tensorbay/opendataset/LeedsSportsPose/loader.py
See Keipoints2D annotation <reference/label_format:Keypoints2D>
for more details.
Note
Since the Leeds Sports Pose dataloader <LeedsSportsPose-dataloader>
above is already included in TensorBay, so it uses relative import. However, the regular import should be used when writing a new dataloader.
../../../docs/code/LeedsSportsPose.py
There are already a number of dataloaders in TensorBay SDK provided by the community. Thus, instead of writing, importing an available dataloader is also feasible.
../../../docs/code/LeedsSportsPose.py
Note
Note that catalogs are automatically loaded in available dataloaders, users do not have to write them again.
Important
See dataloader table <reference/glossary:dataloader>
for dataloaders with different label types.
Optionally, the organized dataset can be visualized by Pharos, which is a TensorBay SDK plug-in. This step can help users to check whether the dataset is correctly organized. Please see features/visualization:Visualization
for more details.
The organized "BSTLD" dataset can be uploaded to TensorBay for sharing, reuse, etc.
../../../docs/code/LeedsSportsPose.py
Similar with Git, the commit step after uploading can record changes to the dataset as a version. If needed, do the modifications and commit again. Please see features/version_control:Version Control
for more details.
Now "Leeds Sports Pose" dataset can be read from TensorBay.
../../../docs/code/LeedsSportsPose.py
In reference/dataset_structure:dataset
"Leeds Sports Pose", there is one reference/dataset_structure:segment
named default
. Get it by passing the segment name or the index.
../../../docs/code/LeedsSportsPose.py
In the default reference/dataset_structure:segment
, there is a sequence of reference/dataset_structure:data
, which can be obtained by index.
../../../docs/code/LeedsSportsPose.py
In each reference/dataset_structure:data
, there is a sequence of reference/label_format:Keypoints2D
annotations, which can be obtained by index.
../../../docs/code/LeedsSportsPose.py
There is only one label type in "Leeds Sports Pose" dataset, which is keypoints2d
. The information stored in x
(y
) is the x (y) coordinate of one keypoint of one keypoints list. The information stored in v
is the visible status of one keypoint of one keypoints list. See reference/label_format:Keypoints2D
label format for more details.
../../../docs/code/LeedsSportsPose.py