Applying hierarchical keywords quickly

Started by barneagle, November 10, 2016, 02:35:01 PM

Previous topic - Next topic

barneagle

I'm trying out the trial version of IMatch with a view to migrating from Windows Essentials Photo Gallery (formerly known as Windows Live Photo Gallery or WLPG).

A major consideration is how quickly and easily I can apply keywords to photos.

For example, my existing keywords include Places/Belgium/Bruges and Places/Switzerland/Brugg; in WLPG if I want to tag a new photo with Places/Belgium/Bruges I type Ctrl-T then start typing brug and the program shows a dropdown list of the existing matching keywords and I can use arrow keys and Enter to choose the one I want. The whole process takes a second or two.

So far as I can see, in IMatch I have to type Ctrl-E then K to activate the keyword pane, then click the mouse in the Enter keywords here box, then type the whole hierarchical keyword (Places/Belgium/Bruges). Unless the keyword I want happens to be listed in the Recent, Top 50, Favourites or Suggestions lists I can't see a quicker way.

Is there a quicker way?

Mario

The Keyword Panel in IMatch has many features to improve keyword input.
It can assign keywords to one or hundreds of files at once.
The thesaurus allows you to setup synonyms and keyword groups which are assigned in batch.
Setting up a thesaurus with controlled keywords avoids a lot of unnecessary typing in the Keyword panel.
Using Favorites you can apply @Keyword categories to your files (one or many) with a single mouse click of keyword shortcut.
-- Mario
IMatch Developer
Forum Administrator
http://www.photools.com  -  Contact & Support - Follow me on 𝕏 - Like photools.com on Facebook

barneagle

Thank you for your quick reply.

I've obviously got a lot of learning to do.

I think I can understand how the features you mention could be extremely useful for applying common keywords or groups of keywords, but would they help for rarely used keywords such as Places/Belgium/Bruges in my example? I don't often take photos there so by definition this would not be a favourite and I presume it would not be practical to define synonyms for all the hundreds (possibly thousands) of keywords like this that exist in my hierarchy.

I guess the issue may not be as big as I first thought. Probably a large majority of keywords that I apply would be accommodated readily by favourites and/or synonyms so the amount of typing would be relatively small.

However, I wonder if there is another potential problem. I assume from your answer that the program does not have a facility for throwing up matches as I type a keyword. In which case what would stop me, in my example, typing and applying "Places/Belgium/Brugge"?

barneagle

I think I've found the answer to my question about what would stop me typing the wrong keyword. I see that if I select the Categories tab in the bottom right of the window I can search. So in my example I could search for brug and select (and apply) the existing Bruges tag.

Mario

#4
1.

When you type in the keyword panel, it displays matches from the keyword entries in your thesaurus.
Did you setup the thesaurus yet? The Keyword panel does not "go out" and searches the keywords in your files or anything, if this is what you expect. (This may work for databases with 20,000 files, but not for the more typical 100,000 to 300,000 files databases)

If you have setup your thesaurus by one of the many supported ways (importing keywords already in your files, importing controlled vocabularies, manually editing the thesaurus,...) the Keyword panel will show you all elements in your thesaurus so you can just pick from them.

it will also use what you type to search the thesaurus and show suggestions:



I think this is what you mean?
I typed mot and the keyword panel shows me keywords containing this term.
The input is also used to filter the thesaurus panel itself, and the recent, favorites and suggestions tabs.

There is a lot of oomph packed int he Keyword panel. Impossible to know all this in the first few hours of use  ;)


2.

IMatch mirrors all hierarchical keywords in your files in the special @Keywords category hierarchy. A ton of features are linked to this. One of the features you discovered s that you can search the category panel and can find keywords. But that's not even the tip of the iceberg. Please search the IMatch help index for @Keywords to learn all about what you can do with it.

3.

The Keyword panel topic in the help explains all this, and also links to the Thesaurus help topic. Note that the IMatch thesaurus does not only handle keywords, it works for all metadata tags. This is why it's named Universal Thesaurus.

See also these articles in the IMatch knowledge base for useful information:

Free Controlled Vocabularies for IMatch

Use Visual Clues to Improve Your Workflow
-- Mario
IMatch Developer
Forum Administrator
http://www.photools.com  -  Contact & Support - Follow me on 𝕏 - Like photools.com on Facebook

barneagle

Thanks. I'll try to follow all this up tomorrow.

barneagle

Thanks for all your help and for the amazingly powerful program you have developed.

I've begun working with the thesaurus. I'm very impressed with the potential and hope that I can accommodate all the keyword tagging that I have done in the past. I've set up a skeleton thesaurus with my top-level keywords manually inserted under WHO, WHERE, WHAT etc. and I've been particularly impressed by how the import from database seems to have slotted all my hierarchical keywords into the appropriate places in the Thesaurus hierarchy.

Can I assume that when I bring more pictures in and repeat the import from database command IMatch will recognise the keywords that have already been imported and won't try to duplicate them in the thesaurus?

I'm afraid I'm getting confused by how the "hierarchy separator" setting works.
All my existing hierarchical keywords use the forward slash (/) as the separator (following the convention used by WLPG).
In the "Hierarchy separator" dropdown box under Keyword Import (in Metadata Preferences) the only item that is ticked is the forward slash (/).
I don't see any other setting for hierarchy separator.
The keywords I have applied using the IMatch thesaurus use |
For example, in a test file the Keywords tag in the IMatch metadata window shows "Places/Croatia/Other Croatia; Other|War memorials; Other|Flags"
(Other Croatia was added in WLPG; I have added War memorials and Flags in IMatch)
Exiftool shows that the same separators have been exported when I click the yellow pen(cil):

---- XMP-microsoft ----
LastKeywordXMP                  : Places/Croatia/Other Croatia
---- XMP-dc ----
Subject                         : Places/Croatia/Other Croatia, Other|Flags, Other|War memorials
---- XMP-lr ----
HierarchicalSubject             : Places/Croatia/Other Croatia, Other|War memorials, Other|Flags


Is it possible for me to get IMatch to stop using the | separator and always use /?


Mario

QuoteCan I assume that when I bring more pictures in and repeat the import from database command IMatch will recognise the keywords that have already been imported and won't try to duplicate them in the thesaurus?
Yes.

QuoteI'm afraid I'm getting confused by how the "hierarchy separator" setting works.
All my existing hierarchical keywords use the forward slash (/) as the separator (following the convention used by WLPG).

Hierarchical keywords in XMP always use | as their separator. That's fixed in the specification.

IMatch allows you to configure an hierarchical separator for import, to transform keyword hierarchies which have been written using some sort of dot-notation (usually: Location.beach.Daytona) into proper hierarchical keywords. IMatch uses the settings you make to detect hierarchy levels and to produce the proper Location|beach|Daytona from it.  That's a comfort and conversion feature for mapping flat->hierarchical. IMatch will always write hierarchcial keywords into XMP using | as the separator - this is am must.

I don't know what software you used before, I have never seen / being used. This is another one of the proprietary Microsoft things that make things so hard once your Microsoft product is discontinued and you need to look for something else.

You need to import your flat keywords (XMP-dc) using the proper separator / set.  IMatch then breaks them up in hierarchies.
On write back, IMatch will always use the standardized | separator to write hierarchies.
Note: XMO-dc is designed to hold flat keywords only. Not hierarchies like in your example. You can control if and how IMatch flattens your true hierarchical keywords as described in the IMatch help.
-- Mario
IMatch Developer
Forum Administrator
http://www.photools.com  -  Contact & Support - Follow me on 𝕏 - Like photools.com on Facebook

barneagle

Thanks for the explanation ... and for making it possible to import hierarchies with incorrect separators (like /). This seems to be working well for me.

The section of the Metadata Preferences help page headed "Write hierarchical keywords" (under Keyword Export) says "The separator character | used to separate the levels can be chosen in the dialog. ... The default | is usually a good choice." This is what led me to think that I might be able to specify a different character.

barneagle

As the IMatch help file says
QuoteWhat character is best depends on the other applications in your tool chain.

Whatever route I follow I shall need the hierarchy separator to be consistently applied. Is there a facility within IMatch to alter all my existing / separators to | ? If not, do you think that an ExifTool command like ExifTool -Sep ", " "-XPKeywords<${XPKeywords;s/\///\|g}" "-XMP:Subject<${XMP:Subject;s/\///\|g}" "-XMP:LastKeywordXMP<${XMP:LastKeywordXMP;s/\///\|g}" FILE/DIR following Phil Harvey's example here http://u88.n24.queensu.ca/exiftool/forum/index.php?topic=6516.0 would do it correctly?

Mario

Usually it works this way:

1. IMatch imports your existing keywords.

2. It there are "hierarchical" keywords in legacy IPTC / XMP:dc it detects these hierarchies using the hierarchy separators you have provided.

3. This produces one set of (hierarchical) keywords. IMatch does not care for flat keywords after that.

4. During write-back, IMatch creates the flat keywords by writing the hierarchical keywords first, then flattening them out into IPTC/XMP.

This should strip all your / from your keywords. Because all keywords are re-written.

Note: IMatch does not care for keywords in the proprietary Microsoft XMP namespace.

Perhaps attach a sample image (zipped) so we can see the metadata mess your other software has created.
-- Mario
IMatch Developer
Forum Administrator
http://www.photools.com  -  Contact & Support - Follow me on 𝕏 - Like photools.com on Facebook

barneagle

Thanks again for all your help.

I've started with a fresh photo and attach txt files created by ExifTool listing metadata at the following stages:
- straight from the camera
- after adding a "tag" (keyword) in WLPG
- after bringing in to IMatch and clicking the yellow pen(cil) ... which added the LR hierarchical tag
- after adding a second keyword in IMatch

I also attach a copy of the final jpg file. In order to reduce the size to meet the 2MB limit I have reduced the pixel size: I hope this won't have interfered with the relevant parts of the metadata.

What I see is that:
IMatch left the XMP-microsoft>LastKeywordXMP unchanged throughout (with / separators and only the first keyword)
IMatch left XMP-dc>Subject with the / separator until the second keyword was added and then applied the | separator for both keywords
IMatch added the XMP-lr>HierarchicalSubject with the | separator for both keywords

In the previous example I quoted above the lr>HierarchicalSubject tag had a mixture of separators: / for the keyword inherited from WLPG and | for the keywords added in IMatch. Could this perhaps be because I omitted the stage of clicking on the yellow pen(cil) before making the edits?

Incidentally, I'm afraid I still don't understand what the Help means when it says the hierarchical separator for Keyword Export "can be chosen in the dialog."

Mario

Your file shows up in IMatch with these hierarchical keywords:

Places of Interest|Woodland
Other|Leaves


It has no legacy IPTC data.

I now click on the pen icon in the Keyword panel (in front of the input filed). This marks the keywords as 'modified'.
Marking the keywords as modified and then writing back the file triggers the mapping process I described above (hierarchical -> flat).

Now I write back. IMatch writes the hierarchical XMP keywords and then maps these to flat XMP-dc keywords using your settings (Edit > Preferences > Metadata).
When I use the Write hierarchical keywords keyword export option, I end up with (correct):

[XMP-dc]        Subject                         : Places of Interest|Woodland, Other|Leaves
[XMP-lr]        Hierarchical Subject            : Places of Interest|Woodland, Other|Leaves


when I disable the Write hierarchical keywords  option, I end up with (correct):

[XMP-dc]        Subject                         : Leaves, Woodland
[XMP-lr]        Hierarchical Subject            : Places of Interest|Woodland, Other|Leaves


when I set the "write path elements", I get (correct)

[XMP-dc]        Subject                         : Leaves, Woodland, Other, Places of Interest
[XMP-lr]        Hierarchical Subject            : Places of Interest|Woodland, Other|Leaves


(after marking the hierarchical keywords as modified and writing-back, each time).
Looks OK to me.

-- Mario
IMatch Developer
Forum Administrator
http://www.photools.com  -  Contact & Support - Follow me on 𝕏 - Like photools.com on Facebook

barneagle

Thanks again for your help. I'm sorry if my questions seem stupid, but I hope the questions and answers might help anyone else trying the same migration (from WLPG to IMatch).

I think part of the problem is that I don't understand the significance of the pen icon. The Introduction Help page says "By clicking on this icon, you can write-back the metadata for this file". The Metadata Panel Help page says "You can click pen to write the changes to the file immediately". But the same page says  "You can also Undo changes made to a tag in the current editing session by clicking on the Pen icon". Does the pen icon do different things in different places?

It's still a mystery to me how in the example I quoted earlier a file ended up with both / and | in the dc:Subject tag. (---- XMP-dc ---- Subject: Places/Croatia/Other Croatia, Other|Flags, Other|War memorials). Did I need to do something to force IMatch to change the separator of the pre-existing Places keyword before adding the other keywords?

I still don't understand what the Metadata Help page means when it says the hierarchical separator for Keyword Export "can be chosen in the dialog."

Mario

#14
The pen icon in the file window starts the write-back process.
It allows you to write-back individual files. An alternative to Commands > Metadata Write-back...

The pen icons in the metadata and keyword panels show you if a tag was modified.
Change the text of a tag in the metadata panel and see how the pen in front of it changes.
This is explained in detail in the corresponding help.

Usually you don't need to do anything with the pen icons in the metadata panel or keyword panel.
They are just visual indicators to help you clearly seeing which tag have been updated and thus have contents not yet written.

In some situations, you can use the pens to explicitly mark a tag (keyword) as modified.
For example, you select 50 files. Then you click on the pen on the 'Title' tag to mark it as modified. Now all 50 files receive this title text when you commit the changes in the Metadata Panel. This is how you can push metadata form one file to many conveniently. You can of course also just edit the text. Whatever works best for you.

I used that little trick to mark the keywords as modified in order to clear up the mess in your files.

IMatch imported a proper set of hierarchical keywords. To fix the mess in the file, I needed IMatch to write-back data.
So I clicked the pen to mark the keywords as modified and the file goes into the "pending write-back" state (the pen icon for the file in the file window shows up).
Instead of clicking the pen I could also have added another keyword or caused some other change to metadata. Same result.
I just needed to tell IMatch that the hierarchcial keywords have changed so it writes them back the next time I write-back the file. This will also push the changes into the flat keywords.

Note: All this is only required because we need to fix your broken keywords. Usually you don't need to do anything special. You import files, you change metadata and keywords, you write back. Completely no-brainer.

The pen in the file window shows you the metadata that needs to be written (in the tooltip) and can be used to trigger the write-back for individual files (or all selected files).

Note: If you think you have found a problem in the help, please use the feedback link at the bottom of each help page fo inform me. I have no idea about which of the over 600 help pages you might have looked at or if the info is wrong or misleading. Send me the feedback, quite the section you find irritating or wrong and I will see what I can do.

-- Mario
IMatch Developer
Forum Administrator
http://www.photools.com  -  Contact & Support - Follow me on 𝕏 - Like photools.com on Facebook

barneagle

I understand that the mess in my files (my broken keywords) needs to be fixed.

It will have to remain a mystery how both the Subject and HierarchicalSubject tags ended up in one of my files with a mixture of / and | separators (as detailed earlier). Following your guidance I hope I shall be able to ensure that the separators are consistent in all my files.

I shall use the feedback link on Help pages as requested.

Thanks again.


barneagle

Sorry. I can't use the Help feedback links. Because I don't have an email app registered with Windows the listed option that seemed relevant to me was Google Chrome (my browser) and I left the "always use this one" box ticked. But all that happens now when I click on a feedback link is that a new Chrome window opens at the home page. I can't see how to get back to using one of the other feedback options.

If I did provide feedback it would fall under two headings (all covered earlier in this thread):

1. The Metadata Help page (it is headed Metadata then Edit>Preferences>Metadata and is the first hit when I search help for "Separator") says the hierarchical separator for Keyword Export "can be chosen in the dialog." I assume this means that the user can determine what hierarchical separator will be used when writing keyword metadata to the HierarchicalSubject and Subject tags. If true I would find it very helpful (and would avoid a lot of the confusion I have been having). However, it seems not to be true.

2. It seems that the yellow pen icon is used in different ways in different contexts. This has caused me confusion. That could have been avoided if each time the yellow pen is mentioned the Help text warned users to be aware that there are different uses and different meanings in other contexts. Searching help for "pen" lists 4 pages where it is mentioned (as well as Release Notes).


Mario

If you cannot use the mailto link, you can send me a email to my support address (https://www.photools.com/support/). Make sure that you right-click the link and include page unique page url of the help page in your email. This allows me to find the page you are referring to. I look into help updates every couple of weeks only, so please also include a link to this community topic in your email.
-- Mario
IMatch Developer
Forum Administrator
http://www.photools.com  -  Contact & Support - Follow me on 𝕏 - Like photools.com on Facebook