Skip to main content
Participant
January 7, 2025
Answered

Smart Collection filename end with odd/even numbers?

  • January 7, 2025
  • 2 replies
  • 480 views

I'm trying to sort the images by odd number and even number filenames using the Smart Collection function. For the odd number smart collection, I set the criteria with any filename ending with 1.jpg, 3.jpg, 5.jpg, and so on. This picked up most of the odd number ending items, exept for the repeating digit numbers, such as 11.jpg, 33.jpg, 55.jpg, etc. I am suspecting, might this be a bug?

I am using Lightroom Classic 2025 14.0.1 Release, Mac OS 15.2.

Correct answer johnrellis

"I also had to add 111.jpg, 222. jpg, etc. to cover them all."

 

As described in the related bug linked above, the bug is triggered by sequences of repeated characters.

2 replies

Rikk Flohr_Photography
Community Manager
January 8, 2025

Additionally, engineering is curious about the workflow here. What necessitates this type of smart collection? 

Rikk Flohr: Adobe Photography Org
Participant
January 8, 2025

Thank you all for your input.

What I did was exactly what JohanElzenga said, and it did work, although I also had to add 111.jpg, 222. jpg, etc. to cover them all. This workaround is ok when the expected digits are not that many, but it would still be a problem if there were many more digits in the numbers.

 

We needed to do this because we scanned about 200 double-sided sheets using a document scanner with a feeder, but the scanner could not precisely crop out the images and included extra space around the sheet. We wanted to batch process to crop out the excess spaces, but the scaned images had two types of alignment: the front side of the sheet left more space at top (odd number images), and the back side had it at the bottom (even number images). This was where the Smart Collection function became handy.

 

However, I also wondered - It would be very helpful if there are some AI cropping tools. It looks like there are tools to "fill" the space with something, but I could not find anything that would simply crop out the excess space. Perhaps what makes it more difficult to automate this is that the space around the image is not really empty/void -- it has a few faint scratched lines from the scanners, and it may be difficult to make it distinguish the line between the content and cropping area.

johnrellis
johnrellisCorrect answer
Legend
January 8, 2025

"I also had to add 111.jpg, 222. jpg, etc. to cover them all."

 

As described in the related bug linked above, the bug is triggered by sequences of repeated characters.

johnrellis
Legend
January 8, 2025

[This post contains formatting and embedded images that don't appear in email. View the post in your Web browser.]

 

It's a bug, very similar to this one from 2011 (still unfixed):

https://community.adobe.com/t5/lightroom-classic-bugs/p-issue-in-text-filter-caption-ends-with/idi-p/12252270 

 

There are a number of such bugs with the smart-collection and filter criteria, outstanding for many years. 

 

Workarounds:

 

1. If you're willing to find do multiple steps to find such files, the text filter "Filename ends with 1.jpg" works correctly.

 

2. Use the Any Filter plugin:

 

JohanElzenga
Community Expert
Community Expert
January 8, 2025

Wouldn't add "Filename ends with 11.jpg", "Filename ends with 33.jpg", etc to the smart collection work?

 

-- Johan W. Elzenga