1
Nxt Projects / Re: Birdlance: decentralized reverse image search JPL-compliant
« on: February 23, 2020, 04:58:12 pm »
Our blockchain API capabilities have been extended with a reverse image search developers API.
Calculate Image Hash
Calculate a perceptual hash of an image by using an URL to the image.
Request:
requestType is calculateImageHash
url is the URL to the image
Response:
hash (S) is the perceptual hash of the image located on the URL
requestProcessingTime (N) is the API request processing time (in millisec)
Example:
Request:
http://18.197.116.35:9085/nxt?requestType=calculateImageHash&url=http://ogsteviestrow.com/wp-content/uploads/2017/09/Patreon-320-320-300x159.png
Response:
{
"imageHash":"f01b07f82fe6f8073a116aac87cb877bfdf86c9a783707e487cc7031044b8c0f","requestProcessingTime":993
}
Perform Image Search
Perform a search by using an image’s perceptual hash or URL.
Request:
requestType is performImageSearch
hash is the perceptual hash of the image; or
secretPhrase is the secret phrase of the funding account
5 BLNC is needed for this request, 4 BLNC gets send to forger of the last block.
Response:
imageSearch (B) is true if the operation completed successfully
requestProcessingTime (N) is the API request processing time (in millisec)
Example:
Request:
http://18.197.116.35:9085/nxt?requestType=performImageSearch&hash=f01b07f82fe6f8073a116aac87cb877bfdf86c9a783707e487cc7031044b8c0f&secretPhrase=IWontTellYou
or
http://18.197.116.35:9085/nxt?requestType=performImageSearch&url=http://www.domain.com/path_to_image.jpg&secretPhrase=IWontTellYou
Response:
{
"requestProcessingTime": 6396,
"imageSearch": [
{
"image_uri": "http:\/\/ogsteviestrow.com\/wp-content\/uploads\/2017\/09\/Patreon-320-320-300x159.png",
"phash": "f01b07f82fe6f8073a116aac87cb877bfdf86c9a783707e487cc7031044b8c0f",
"base_uri": "http:\/\/ogsteviestrow.com"
}
]
}
Whats next?
Read full here:https://medium.com/birdlance/decentralized-reverse-image-search-blockchain-api-8b5f261f0fbf
Calculate Image Hash
Calculate a perceptual hash of an image by using an URL to the image.
Request:
requestType is calculateImageHash
url is the URL to the image
Response:
hash (S) is the perceptual hash of the image located on the URL
requestProcessingTime (N) is the API request processing time (in millisec)
Example:
Request:
http://18.197.116.35:9085/nxt?requestType=calculateImageHash&url=http://ogsteviestrow.com/wp-content/uploads/2017/09/Patreon-320-320-300x159.png
Response:
{
"imageHash":"f01b07f82fe6f8073a116aac87cb877bfdf86c9a783707e487cc7031044b8c0f","requestProcessingTime":993
}
Perform Image Search
Perform a search by using an image’s perceptual hash or URL.
Request:
requestType is performImageSearch
hash is the perceptual hash of the image; or
secretPhrase is the secret phrase of the funding account
5 BLNC is needed for this request, 4 BLNC gets send to forger of the last block.
Response:
imageSearch (B) is true if the operation completed successfully
requestProcessingTime (N) is the API request processing time (in millisec)
Example:
Request:
http://18.197.116.35:9085/nxt?requestType=performImageSearch&hash=f01b07f82fe6f8073a116aac87cb877bfdf86c9a783707e487cc7031044b8c0f&secretPhrase=IWontTellYou
or
http://18.197.116.35:9085/nxt?requestType=performImageSearch&url=http://www.domain.com/path_to_image.jpg&secretPhrase=IWontTellYou
Response:
{
"requestProcessingTime": 6396,
"imageSearch": [
{
"image_uri": "http:\/\/ogsteviestrow.com\/wp-content\/uploads\/2017\/09\/Patreon-320-320-300x159.png",
"phash": "f01b07f82fe6f8073a116aac87cb877bfdf86c9a783707e487cc7031044b8c0f",
"base_uri": "http:\/\/ogsteviestrow.com"
}
]
}
Whats next?
- Integrate our reverse image search with each node. Each node will crawl the web to improve our reversed image search. This means that the more nodes the birdlance blockchain network has, the more powerful our reverse image search will become. We will contineously work on improvements to the blockchain to make our reversed image search smarter and self-sustainable.
- Our indexed data (hash and image url) is too big to store on chain. To be truely succesful we need around 40 billion of crawled image data. Right now this data is centralized. We are working on an OrbitDB(P2P database) to make this decentralized.
- Integrate our reversed image search APIs in the next node update. Everyone will then be able to use his/her own node for our reversed image search APIs by simply enabling the API functionalities of their node (setting in the properties file).
Read full here:https://medium.com/birdlance/decentralized-reverse-image-search-blockchain-api-8b5f261f0fbf