Python program using Selenium and BeautifulSoup4 to generate the average of listed seasons of a TV Show from IMDb. It is a straightforward process to see the ratings of individual ratings of the season in Metacritic, but most often they lack the ratings and show a blank image even for decades old emmy winning TV shows. IMDb does not have this feature, at least not in a easily discernible way. This program scrapes and displays the average ratings of each season.
IMDb data | Metacritic data |
---|---|
Before you run the script install,
pip install selenium
pip install beautifulsoup4
Additionally, you also need to install a web driver for Selenium to access. You can install chrome driver from below link.
https://chromedriver.chromium.org/downloads
Note: Chrome driver must me added to PATH or include the path in the code like this.
Make sure you install the same release of chrome driver as your chrome web browser. You can check your version through the below link.
chrome://version/
If you wish to use other drivers (Edge for Microsoft Edge and Gecko for Firefox). Change Chrome()
to your desired driver. For example, Edge()
in Line 9 in the code.
driver= webdriver.Chrome()
A executable file (.exe) for Windows operating system has been made using pyintstaller
that lets you use the program without the hassles of installing libraries you're not familiar with. This also requires you to install a web driver. This will not function without a web driver. Click here to download the release.