Spaces:
Runtime error
Runtime error
Ahsen Khaliq
commited on
Commit
•
2192db2
1
Parent(s):
3e819c8
Update app.py
Browse files
app.py
CHANGED
@@ -32,6 +32,10 @@ torch.hub.download_url_to_file('https://user-images.githubusercontent.com/1328/1
|
|
32 |
torch.hub.download_url_to_file('https://cdn.pixabay.com/photo/2021/08/23/17/53/cat-6568422_1280.jpg', 'cat1.jpg')
|
33 |
torch.hub.download_url_to_file('https://i.imgur.com/fMoVhSz.png', 'cat2.png')
|
34 |
|
|
|
|
|
|
|
|
|
35 |
|
36 |
|
37 |
|
@@ -85,7 +89,7 @@ def inference(img, img2):
|
|
85 |
title = "AppleNeuralHash"
|
86 |
description = "Gradio demo for Apple NeuralHash, a perceptual hashing method for images based on neural networks. It can tolerate image resize and compression. To use it, simply upload your image, or click one of the examples to load them. Read more at the links below."
|
87 |
article = "<p style='text-align: center'><a href='https://www.apple.com/child-safety/pdf/CSAM_Detection_Technical_Summary.pdf'>CSAM Detection Technical Summary</a> | <a href='https://github.com/AsuharietYgvar/AppleNeuralHash2ONNX'>Github Repo</a> | <a href='https://github.com/AsuharietYgvar/AppleNeuralHash2ONNX/issues/1'>Working Collision example images from github issue</a></p> "
|
88 |
-
examples = [['sunset.jpg','rotate.png'],['dog.png','same.png'],['cat1.jpg','cat2.png']]
|
89 |
|
90 |
gr.Interface(
|
91 |
inference,
|
32 |
torch.hub.download_url_to_file('https://cdn.pixabay.com/photo/2021/08/23/17/53/cat-6568422_1280.jpg', 'cat1.jpg')
|
33 |
torch.hub.download_url_to_file('https://i.imgur.com/fMoVhSz.png', 'cat2.png')
|
34 |
|
35 |
+
torch.hub.download_url_to_file('https://cdn.pixabay.com/photo/2021/08/10/09/41/lesser-sand-plover-6535531_1280.jpg', 'bird1.jpg')
|
36 |
+
torch.hub.download_url_to_file('https://i.imgur.com/jDgKAC7.png', 'bird2.png')
|
37 |
+
|
38 |
+
|
39 |
|
40 |
|
41 |
|
89 |
title = "AppleNeuralHash"
|
90 |
description = "Gradio demo for Apple NeuralHash, a perceptual hashing method for images based on neural networks. It can tolerate image resize and compression. To use it, simply upload your image, or click one of the examples to load them. Read more at the links below."
|
91 |
article = "<p style='text-align: center'><a href='https://www.apple.com/child-safety/pdf/CSAM_Detection_Technical_Summary.pdf'>CSAM Detection Technical Summary</a> | <a href='https://github.com/AsuharietYgvar/AppleNeuralHash2ONNX'>Github Repo</a> | <a href='https://github.com/AsuharietYgvar/AppleNeuralHash2ONNX/issues/1'>Working Collision example images from github issue</a></p> "
|
92 |
+
examples = [['sunset.jpg','rotate.png'],['dog.png','same.png'],['cat1.jpg','cat2.png'],['bird1.jpg','bird2.png']]
|
93 |
|
94 |
gr.Interface(
|
95 |
inference,
|