Best way to apply associated keywords automatically

Started by plastikman, April 01, 2020, 10:58:41 AM

Previous topic - Next topic

plastikman

A question from a new IMatch 2020 user:

I have the following case:

  • I have a daughter named Name. Keyword: Person|Name
  • Her gender is female. Keyword: Gender|female
  • She is a girl (until she turns into a woman). Keyword: Age|Children|girl
  • She is a toddler (until she becomes a preschooler). Keyword: Age|Stage|toddler
  • She belongs to a Family. Keyword: Person|Families|Family

If I add all of these in the Person editor under Keywords, they are automatically applied. However, my concern is with the changing variables (Age/Stage). If these change and I update the automatically applied keywords, does IMatch change all of them including the ones where she was in a different stage e.g. Baby/Newborn or when someone goes from child to adult?

The person editor has this functionality but for pets (e.g. dog name, dog breed, gender, age) or other items that have multiple associated keywords this doesn't work. How would I solve that? Mario pointed me at Synonyms before but from what I understand they are separate from my Thesaurus so I cannot apply Age|Stage|toddler[/li][/list] as a Synonym but only "toddler" which would then be a separate entry in @Keywords.

It would be great to have a way similar to the Person editor: when applying Keyword A also apply Keyword B, C, D, E, F etc. automatically. In a simple flat keyword world I would use Synonyms, but it then creates huge inconsistencies between keywords applied from the Thesaurus and ones applied as Synonyms. I hope I am missing some part of this and I can make it work.

Any input about your approach is welcome since I prefer to figure these things out before I start applying keywords to 20,000 images in batches ;D

Mario

Person keywords are applied when the person is assigned/confirmed.
When you change person keywords, they are changed for all files linked to that person.

Things like "Age|Children|girl" or "Age|Stage|toddler" are really not suitable for automatic assignment.
These should be assigned by hand or maybe filled using a Metadata Template or the Metadata Wizard. The age of the person in the image is available via a variable and this could be used to conditionally assign a keyword like one of these.

I'm not sure about your synonym question. They are not "separate" or whatever.
A synonym is linked to a keyword and when you assign the keyword, the synonyms are assigned as well.
This is explained in great detail in the IMatch help system.

QuoteIt would be great to have a way similar to the Person editor: when applying Keyword A also apply Keyword B, C, D, E, F etc. automatically

1. Add all keywords you want to assign in the Person Editor.
2. When a keyword has synonyms at the time the person is assigned/confirmed, these will also be assigned. Like any other keywords.
3. Changing synonyms after the fact will not change the keywords already assigned to the file.
You can force an update by removing and re-adding the corresponding keyword. This will remove/add synonyms based on the current state of the thesaurus.
-- Mario
IMatch Developer
Forum Administrator
http://www.photools.com  -  Contact & Support - Follow me on 𝕏 - Like photools.com on Facebook

plastikman

Thanks for your follow-up. I will give it some thought.

From what I observe, adding "female" as a Synonym to my daughter's Name keyword doesn't create any relation to "Gender|female". Should I assign the full hierarchy as a Synonym e.g. "Gender|female;Age|girl"?

Quote from: Mario on April 01, 2020, 11:10:28 AM
These should be assigned by hand or maybe filled using a Metadata Template or the Metadata Wizard. The age of the person in the image is available via a variable and this could be used to conditionally assign a keyword like one of these.

This I want to explore more since I think it would be the best way to define "life stages" based on age/year/months and then semi-automatically assign them to the entire library every now and then since it is not a critical keyword like a Name, Location etc.

Thanks again for the guidance.

Mario

Quotefemale" as a Synonym to my daughter's Name
How should that work?

YourNameHere (keyword)
|- female (synonym)

How should IMatch know that the synonym female of the keyword YoruNameHere should produce an unrelated keyword in the Gender hierarchy => "Gender|female".
Unless you make "Gender" a group keyword and hence assigning Gender|female produces "female". Then the synonym would work because there is no hierarchy anymore.

Synonyms are used for things like

Gender|female
|- feminine
|- weiblich
|- feminin

When you now assign the keyword Gender|female to a file, the additional keywords (based on the synonyms) are added:

Gender|feminine
Gender|weiblich
Gender|feminin

If you setup YourNameHere as a keyword for the Person YourNameHere, just add Gender|female too. You can use any number of keywords. And the gender does usually not change over time.
This is why keywords like "Age|Toddler" should not be used for Person keywords - because this keyword is age-dependent.
-- Mario
IMatch Developer
Forum Administrator
http://www.photools.com  -  Contact & Support - Follow me on 𝕏 - Like photools.com on Facebook

plastikman

Quote from: Mario on April 01, 2020, 12:44:32 PM
If you setup YourNameHere as a keyword for the Person YourNameHere, just add Gender|female too. You can use any number of keywords. And the gender does usually not change over time.
This is why keywords like "Age|Toddler" should not be used for Person keywords - because this keyword is age-dependent.

Thanks this clears it up how to proceed with the person keywords, I will keep them minimal.

I was just now experimenting with data-driven categories with the following variable:
{File.Persons.Age.Months|between:1,3,Newborn}{File.Persons.Age.Months|between:3,18,Baby}{File.Persons.Age.Months|between:19,42,Toddler}

However, photos of the first month of a child (month 0) don't show up in this filter. However, if I use 0,3 instead of 1,3 all the photos without a person or with a person with another age that is not filtered show up there (e.g. the same as "Other" category). How do I filter the first 3 months of someone's life without getting all the null values included?

The other question I have is how you can make this specific to a person based on Keyword/Category e.g. YourNameHere.

Mario

What does {File.Persons.Age.Months} return for the person?
It should return 0 when the person's age is less than one month?
-- Mario
IMatch Developer
Forum Administrator
http://www.photools.com  -  Contact & Support - Follow me on 𝕏 - Like photools.com on Facebook

plastikman

Quote from: Mario on April 01, 2020, 03:01:02 PM
What does {File.Persons.Age.Months} return for the person?
It should return 0 when the person's age is less than one month?

No value (VarToy result field is empty). If I find a picture of my wife with newborn daughter (both tagged as a person) it only returns my wife's age (e.g. verbose XXX months). The first value I get for pictures with my newborn daughter in them is when she is "1 month" or older (value = 1).

Mario

It should return 0, I guess.
Please open a bug report and describe your finding.
-- Mario
IMatch Developer
Forum Administrator
http://www.photools.com  -  Contact & Support - Follow me on 𝕏 - Like photools.com on Facebook

plastikman