Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[DOC] Add docs for missing datasets #3536

Merged
merged 8 commits into from
Mar 12, 2021
Merged
Show file tree
Hide file tree
Changes from 7 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 25 additions & 0 deletions docs/source/datasets.rst
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,18 @@ All the datasets have almost similar API. They all have two common arguments:

.. currentmodule:: torchvision.datasets


Caltech
~~~~~~~

.. autoclass:: Caltech101
:members: __getitem__
:special-members:

.. autoclass:: Caltech256
:members: __getitem__
:special-members:

CelebA
~~~~~~

Expand Down Expand Up @@ -192,6 +204,13 @@ SBU
:members: __getitem__
:special-members:

SEMEION
~~~~~~~

.. autoclass:: SEMEION
:members: __getitem__
:special-members:

STL10
~~~~~

Expand Down Expand Up @@ -231,3 +250,9 @@ VOC
:members: __getitem__
:special-members:

WIDERFace
~~~~~~~~~

.. autoclass:: WIDERFace
:members: __getitem__
:special-members:
1 change: 1 addition & 0 deletions torchvision/datasets/kinetics.py
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,7 @@ class Kinetics400(VisionDataset):

Args:
root (string): Root directory of the Kinetics-400 Dataset. Should be structured as follows:

.. code::

root/
Expand Down
5 changes: 4 additions & 1 deletion torchvision/datasets/semeion.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,8 @@


class SEMEION(VisionDataset):
"""`SEMEION <http://archive.ics.uci.edu/ml/datasets/semeion+handwritten+digit>`_ Dataset.
r"""`SEMEION <http://archive.ics.uci.edu/ml/datasets/semeion+handwritten+digit>`_ Dataset.

Args:
root (string): Root directory of dataset where directory
``semeion.py`` exists.
Expand All @@ -19,6 +20,7 @@ class SEMEION(VisionDataset):
download (bool, optional): If true, downloads the dataset from the internet and
puts it in root directory. If dataset is already downloaded, it is not
downloaded again.

"""
url = "http://archive.ics.uci.edu/ml/machine-learning-databases/semeion/semeion.data"
filename = "semeion.data"
Expand Down Expand Up @@ -53,6 +55,7 @@ def __getitem__(self, index: int) -> Tuple[Any, Any]:
"""
Args:
index (int): Index

Returns:
tuple: (image, target) where target is index of the target class.
"""
Expand Down
4 changes: 4 additions & 0 deletions torchvision/datasets/widerface.py
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,9 @@ class WIDERFace(VisionDataset):
Args:
root (string): Root directory where images and annotations are downloaded to.
Expects the following folder structure if download=False:

.. code::
oke-aditya marked this conversation as resolved.
Show resolved Hide resolved

<root>
└── widerface
├── wider_face_split ('wider_face_split.zip' if compressed)
Expand All @@ -29,6 +32,7 @@ class WIDERFace(VisionDataset):
download (bool, optional): If true, downloads the dataset from the internet and
puts it in root directory. If dataset is already downloaded, it is not
downloaded again.

"""

BASE_FOLDER = "widerface"
Expand Down