from PIL import Image
from pytesseract import image_to_string
import requests
from io import BytesIO
import re
url = 'https://pbs.twimg.com/media/Dh-ZHUPX4AAQwG-.jpg:large'
response = requests.get(url)
img = Image.open(BytesIO(response.content))
text_from_image = image_to_string(img)
print(text_from_image)