I am running this code to compare the similarity of two profile images belonging to two different social networks, i am first downloading the images from the two websites,and then for each user,i give the local images paths to two variables, i wonder if there is any alternative that allow me to manipulate those images online instead of downloading them, ie: giving the code image's URL instead of local path (i don't want to download the images on my local machine, cause it will take too much space when dealing with millions of them)
from PIL import Image
import imagehash
hash0 = imagehash.average_hash(Image.open('quora_photo.jpg'))
hash1 = imagehash.average_hash(Image.open('twitter_photo.jpeg'))
cutoff = 5
if hash0 - hash1 < cutoff:
print('images are similar')
else:
print('images are not similar')