Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add analysis dates to PhotoInfo #1494

Open
RhetTbull opened this issue Apr 6, 2024 · 0 comments
Open

Add analysis dates to PhotoInfo #1494

RhetTbull opened this issue Apr 6, 2024 · 0 comments
Labels
feature request New feature or request

Comments

@RhetTbull
Copy link
Owner

See below and at this thread for more details on attributes to include.

@Conzpiral I'm not 100% certain this will do the trick but I think it's a good start. When the photo analysis process runs on a photo it updates a date stamp of when the analysis took place. OSXPhotos doesn't provide a way to directly access this but it can be queried using the tables() method which lets you access the underlying database tables. The following will run very slowly as it's got to run a query for every single photo in the library but it will find all photos that have not been analyzed. You can add --count just to see the total count or --add-to-album "Album name" to add the found photos to a given album.

osxphotos query --not-shared --query-eval "not photo.shared_moment" --query-eval "photo.tables().ZASSET.ZANALYSISSTATEMODIFICATIONDATE[0] is None"

The --not-shared and --query-eval "not photo.shared_moment" exclude images from shared albums and shared moments (photos shared as a group via Messages) which won't be analyzed.

If this doesn't give a result close to what you're expecting let me know and I'll dig further.

Originally posted by @RhetTbull in #1487 (reply in thread)

@RhetTbull RhetTbull added the feature request New feature or request label Apr 6, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
feature request New feature or request
Projects
None yet
Development

No branches or pull requests

1 participant