deeplearning / Places365Classifier / 0.1.9
1. Introduction
This is an image classifier specifically trained for classifying various places. The list of places can be found here.
Input:
- (Required) Image Data API Url, Web (http/https) Url, binary image or a base64 encoded image.
- (Optional)?Number of results. (Default=5)
Output:
- Top N classifications.
Note: The first call to this algorithm will take a bit longer than sequential calls to due algorithm initialization. All following calls will be significantly faster.
2. Examples
Example 1.
- Parameter 1: Data API Url
{
"image": "data://deeplearning/example_data/burj_khalifa.jpg"
}
Output
{
"predictions": [
{"class": "tower", "prob": 0.6098036170005801},
{"class": "skyscraper", "prob": 0.14249812066555023},
{"class": "office_building", "prob": 0.04916094988584519},
{"class": "downtown", "prob": 0.02924365177750587},
{"class": "church/outdoor", "prob": 0.028504755347967155}
]
}
Example 2.
- Parameter 1: HTTP Url
{
"image": "https://s3.amazonaws.com/algorithmia-assets/algo_desc_images/deeplearning_Places365Classifier/airfield.jpg"
}
Output:
{
"predictions": [
{"class": "airfield", "prob": 0.5347753167152406},
{"class": "runway", "prob": 0.2845350205898285},
{"class": "heliport", "prob": 0.09564844518899919},
{"class": "landing_deck", "prob": 0.034962698817253106},
{"class": "raceway", "prob": 0.02728229202330112}
]
}
Example 3.
- Parameter 1: Base64 image
{
"image": "data:image/png;base64....",
}
Output;
{
"results":[
{"class": "archive", "prob": 0.16057744622230533},
{"class": "beauty_salon", "prob": 0.11514712870121004},
{"class": "dressing_room", "prob": 0.06852224469184875},
{"class": "biology_laboratory", "prob": 0.044164657592773444},
{"class": "coffee_shop", "prob": 0.037719260901212685}
]
}
Example 4.
- Parameter 1: Data API Url
- Parameter 2: Number of results.
{
"image": "data://deeplearning/example_data/coast.jpg",
"numResults": 15
}
Output:
{
"predictions": [
{"class": "islet", "prob": 0.5723654627799988},
{"class": "cliff", "prob": 0.13769967854022983},
{"class": "coast", "prob": 0.1219320520758629},
{"class": "ocean", "prob": 0.05200425907969475},
{"class": "lagoon", "prob": 0.034720458090305335},
{"class": "harbor", "prob": 0.01532892324030399},
{"class": "lake/natural", "prob": 0.01080096885561943},
{"class": "village", "prob": 0.008164397440850735},
{"class": "valley", "prob": 0.005376808345317839},
{"class": "mountain", "prob": 0.0051351888105273255},
{"class": "river", "prob": 0.004809863399714232},
{"class": "butte", "prob": 0.00298486975952983},
{"class": "sky", "prob": 0.002884584246203304},
{"class": "beach", "prob": 0.0028554031159728765},
{"class": "rainforest", "prob": 0.002376777119934559}
]
}
3. Credits
For more information please refer to: Places: An Image Database for Deep Scene Understanding B. Zhou, A. Khosla, A. Lapedriza, A. Torralba and A. Oliva Arxiv, 2016
Trained model was retrieved from: Places2.
Demo image were retrieved from Wikipedia:
https://en.wikipedia.org/wiki/Skyscraper#/media/File:Burj_Khalifa.jpg
https://en.wikipedia.org/wiki/Airport#/media/File:HFX_Airport_4.jpg
https://en.wikipedia.org/wiki/Harbor#/media/File:Anacapri_BW_2013-05-14_13-32-36.jpg