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

Fix link to LabeledVideoDataset in tutorial #227

Open
wants to merge 1 commit into
base: main
Choose a base branch
from
Open
Changes from all 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
2 changes: 1 addition & 1 deletion website/docs/tutorial_classification.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ To start off with, let's prepare the data and setup the PyTorchVideo Kinetics da

To prepare the Kinetics dataset, you'll need the list of videos found on the Kinetics website [here](https://deepmind.com/research/open-source/kinetics) (any of the Kinetics versions will work). You'll then need the official [download script](https://github.com/activitynet/ActivityNet/tree/master/Crawler/Kinetics) to download the videos. Once downloaded, point the ``pytorchvideo.data.Kinetics`` ``data_path`` arg to the folder of classes (each class folder contains the videos) and the data loader will work. Note that for our model-zoo, we also downsample the Kinetics videos to 256 on the short size to speed up training, see more details in the [data preparation docs](https://pytorchvideo.readthedocs.io/en/latest/data_preparation.html).

The PyTorchVideo Kinetics dataset is just an alias for the general [``pytorchvideo.data.LabeledVideoDataset``](http://pytorchvideo.org/api/data/encoded_video.html#pytorchvideo.data.labeled_video_dataset.LabeledVideoDataset) class. If you look at its constructor, you'll notice that most args are what you'd expect (e.g. path to data). However, there are a few args that are more specific to PyTorchVideo datasets:
The PyTorchVideo Kinetics dataset is just an alias for the general [``pytorchvideo.data.LabeledVideoDataset``](https://pytorchvideo.readthedocs.io/en/latest/api/data/data.html#pytorchvideo.data.LabeledVideoDataset) class. If you look at its constructor, you'll notice that most args are what you'd expect (e.g. path to data). However, there are a few args that are more specific to PyTorchVideo datasets:
- video_sampler - defining the order to sample a video at each iteration. The default is a "random".
- clip_sampler - defining how to sample a clip from the chosen video at each iteration. For a train partition it is typical to use a "random" clip sampler (i.e. take a random clip of the specified duration from the video). For testing, typically you'll use "uniform" (i.e. uniformly sample all clips of the specified duration from the video) to ensure the entire video is sampled in each epoch.
- transform - this provides a way to apply user defined data preprocessing or augmentation before batch collating by the PyTorch data loader. We'll show an example using this later.
Expand Down