Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import requests
- from bs4 import BeautifulSoup
- import pytesseract
- from PIL import Image
- r = requests.get('http://challenge01.root-me.org/programmation/ch8/')
- data = r.text
- soup = BeautifulSoup(data, 'html.parser')
- for imgtag in soup.find_all('img'):
- img = imgtag['src']
- print(imgtag['src'])
- image = Image.open('index.png')
- print(pytesseract.image_to_string(image))
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement