12.18 azcv tags

The tags command takes an image (url or path to a local file) and generates a collection of tags that identify key elements of the image. Each tag has a confidence.

$ ml tags azcv https://bit.ly/3cqDonC
1.00,sky
1.00,outdoor
1.00,sunset
0.99,grass
0.99,mountain
0.99,nature
0.96,landscape
0.94,cloud
0.94,plant
0.93,canyon
...

$ ml tags azcv https://images.pexels.com/photos/338515/pexels-photo-338515.jpeg
1.00,sky
0.99,outdoor
0.98,tower
0.94,cloud
0.80,city
0.79,skyscraper
$ ml tags azcv http://cdn1.thr.com/sites/default/files/2013/11/marina_bay_sands_singapore_a_l.jpg
0.99,sky
0.99,ship
0.99,water
0.96,skyscraper
0.95,outdoor
0.95,scene
0.94,boat
0.89,harbor
0.85,lake
0.77,bridge
0.74,city
0.69,watercraft
0.67,building
0.51,dock
0.40,docked

How Many Tags Identified in an Image

$ ml tags azcv img.jpg | wc -l
6

How Many High Confidence Tags Identified

$ ml tags azcv img.jpg | awk '$1 > 0.90 {print}' | wc -l
5

Identify Tags from a Folder of Images

$ for f in *.jpg; do echo ==== $f ====; ml tags azcv $f; done
==== 20190610_133243.jpg ====
1.00,indoor
0.99,furniture
0.95,bathroom
0.90,design
0.75,sink
0.61,drawer
0.60,home appliance
==== 20190610_143537.jpg ====
0.94,screenshot
0.92,book
0.91,poster
0.88,indoor
0.63,art
0.59,mobile phone
[...]

$ ml tags azcv https://access.togaware.com/landmark02.jpg
1.00,building
0.99,outdoor
0.99,sky
0.85,city
0.74,window
0.57,skyscraper
0.55,architecture
0.51,tall

$ ml describe azcv https://access.togaware.com/landmark02.jpg
0.92,a large skyscraper in front of Taipei 101
0.92,a large skyscraper in front of a tall building with Taipei 101 in the background
0.92,a tall building with Taipei 101 in the background


Your donation will support ongoing availability and give you access to the PDF version of this book. Desktop Survival Guides include Data Science, GNU/Linux, and MLHub. Books available on Amazon include Data Mining with Rattle and Essentials of Data Science. Popular open source software includes rattle, wajig, and mlhub. Hosted by Togaware, a pioneer of free and open source software since 1984. Copyright © 1995-2022 Graham.Williams@togaware.com Creative Commons Attribution-ShareAlike 4.0