Score:0

How do I use imagick to find all images that are not sized 600x300 in my current folder and all its subdirectories?

cn flag

I want to find all images that are NOT equal to a size (600x300) in my current folder and all subdirectories. What should I do?

I tried this but it's not working:

find . -iname "*.png" -type f -exec identify -format '%w %h %i' '{}' \; | awk '$1<>600 && $2<>300'

I also tried this, but the terminal got stuck for more than half an hour:

find . -iname "*.png" -type f -exec identify -format '%w %h %i' '{}' \; | awk '$1!=600 && $2!=300'

Someone avatar
my flag
Try: `find . -iname "*.png" -type f -exec identify -format '%w %h %i' '{}' \; | grep -v "600,300" `
AGamePlayer avatar
cn flag
I tried it. Still got stuck. Is it because I have too many files? (about 3,000-4,000 files in 500-600 directoires)
Someone avatar
my flag
Yes, exactly. If you've that many files than you should expect lags and freezes.
mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.