'Get dataset cover image from kaggle using python selenium web scraping
Hi, Please how can i scrap the cover image of datasets from kaggle using python selenium ? or just get the value of "src" of the HTML
View img => image of inspect elem
Solution 1:[1]
This code uses selenium to get the source of the cover image element and then download it using requests:
import requests
from selenium import webdriver
driver= webdriver.Chrome()
driver.get(kaggle_website)
cover_src = driver.find_element_by_xpath('xpath/to/image').get_attribute("src")
response = requests.get(cover_src)
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|---|
| Solution 1 | ZhorGen |
