Download Subtitles Automatically on Qnap with Python Subliminal

Using Subliminal, you can download the subtitles of movies and tv shows to your Qnap. It uses guessit library to extract Video information and then downloads the subtitles for your video from the internet.
To install Subliminal on Qnap, you would need the terminal SSH access to your qnap.
  1. Install Python
Subliminal doesn’t work with Python3 so you will need python 2.7. This can be done easily from App center.
Go to App center and search for python. Install the 2.7 version .
  1. Install Pip
PIP is not installed by default. The easiest way to install is through get-pip .
download the script first with Curl. Use -k for no verify
curl -O https://bootstrap.pypa.io/get-pip.py -k
run the setup script
python get-pip.py
  1. install Suliminal with pip

Since you have PIP installed, it only takes 1 line command to download and install subliminal and all the dependencies

python -m pip install subliminal
  1. Create softlink to your /usr/bin
Create a softlink to your subliminal installation in your user bin folder so it’s easier to execute. If you choose not to do this, you can still run subliminal from the directory /share/MD0_DATA/.qpkg/Python/bin/
ln -s /share/MD0_DATA/.qpkg/Python/bin/subliminal   /usr/bin/
In case you run into installation problem, install pytest-runner and guessit using pip before installing subliminal.
Using Subliminal to Downlaod Subtitles
you can use subliminal as
subliminal -l en -a 24h /share/MD0_DATA/Download
it will scan your Download directory and  download English subtitles for all the videos that are 24 hours old.  on the first run you can remove the -a option to scan the entire directory. However on subsequent runs, use the ageing flag. If don’t, then it will take a long time to scan the entire directory and repeatedly searching for a subtitle of the same video may get you banned from the subtitle providers.
You can also add it to your crontab to run every 24 hours.