from urllib.request import Request,urlopen,urlretrieve
import urllib
from bs4 import BeautifulSoup
key = input("Enter the image to be searched \n")
urlpath = "https://www.google.com/search?
q="+key+"&source=lnms&tbm=isch&sa=X&ved=0ahUKEwiE9-
7LjobfAhXCEHIKHQy6A00Q_AUIDigB&biw=1920&bih=947#imgrc=_"
page_req = Request(urlpath, headers={'User-Agent': 'Mozilla/5.0'})
page= urlopen(page_req).read()
soup =BeautifulSoup(page,'html.parser')
images= soup.find_all('img')
print("Total"+str(len(images)))
image_links=[]
for img in images:
image_links.append(img.get('src'))
image_count=0
for link in image_links:
urlretrieve(link,'image_'+str(image_count)+'.jpg')
image_count+=1
Приведенный выше скрипт обнаруживает только 20 тегов изображений на странице изображений Google.Почему он не может обнаружить все теги изображений на веб-странице?