Video¶
-
subliminal.video.VIDEO_EXTENSIONS¶ Video extensions
-
class
subliminal.video.Video(name, format=None, release_group=None, resolution=None, video_codec=None, audio_codec=None, imdb_id=None, hashes=None, size=None, subtitle_languages=None)[source]¶ Base class for videos.
Represent a video, existing or not.
Parameters: - name (str) – name or path of the video.
- format (str) – format of the video (HDTV, WEB-DL, BluRay, …).
- release_group (str) – release group of the video.
- resolution (str) – resolution of the video stream (480p, 720p, 1080p or 1080i).
- video_codec (str) – codec of the video stream.
- audio_codec (str) – codec of the main audio stream.
- imdb_id (str) – IMDb id of the video.
- hashes (dict) – hashes of the video file by provider names.
- size (int) – size of the video file in bytes.
- subtitle_languages (set) – existing subtitle languages.
-
name= None¶ Name or path of the video
-
format= None¶ Format of the video (HDTV, WEB-DL, BluRay, …)
-
release_group= None¶ Release group of the video
-
resolution= None¶ Resolution of the video stream (480p, 720p, 1080p or 1080i)
-
video_codec= None¶ Codec of the video stream
-
audio_codec= None¶ Codec of the main audio stream
-
imdb_id= None¶ IMDb id of the video
-
hashes= None¶ Hashes of the video file by provider names
-
size= None¶ Size of the video file in bytes
-
subtitle_languages= None¶ Existing subtitle languages
-
exists¶ Test whether the video exists
-
age¶ Age of the video
-
classmethod
fromguess(name, guess)[source]¶ Create an
Episodeor aMoviewith the given name based on the guess.Parameters: Raise: ValueErrorif the type of the guess is invalid
-
classmethod
fromname(name)[source]¶ Shortcut for
fromguess()with a guess guessed from the name.Parameters: name (str) – name of the video.
-
class
subliminal.video.Episode(name, series, season, episode, title=None, year=None, original_series=True, tvdb_id=None, series_tvdb_id=None, series_imdb_id=None, **kwargs)[source]¶ Episode
Video.Parameters: - series (str) – series of the episode.
- season (int) – season number of the episode.
- episode (int) – episode number of the episode.
- title (str) – title of the episode.
- year (int) – year of the series.
- original_series (bool) – whether the series is the first with this name.
- tvdb_id (int) – TVDB id of the episode.
- **kwargs – additional parameters for the
Videoconstructor.
-
series= None¶ Series of the episode
-
season= None¶ Season number of the episode
-
episode= None¶ Episode number of the episode
-
title= None¶ Title of the episode
-
year= None¶ Year of series
-
original_series= None¶ The series is the first with this name
-
tvdb_id= None¶ TVDB id of the episode
-
series_tvdb_id= None¶ TVDB id of the series
-
series_imdb_id= None¶ IMDb id of the series
-
classmethod
fromguess(name, guess)[source]¶ Create an
Episodeor aMoviewith the given name based on the guess.Parameters: Raise: ValueErrorif the type of the guess is invalid
-
classmethod
fromname(name)[source]¶ Shortcut for
fromguess()with a guess guessed from the name.Parameters: name (str) – name of the video.
-
class
subliminal.video.Movie(name, title, year=None, **kwargs)[source]¶ Movie
Video.Parameters: -
title= None¶ Title of the movie
-
year= None¶ Year of the movie
-
classmethod
fromguess(name, guess)[source]¶ Create an
Episodeor aMoviewith the given name based on the guess.Parameters: Raise: ValueErrorif the type of the guess is invalid
-
classmethod
fromname(name)[source]¶ Shortcut for
fromguess()with a guess guessed from the name.Parameters: name (str) – name of the video.
-