Make Using XMP Metadata to Enhance Image Search Optional, Configurable

- Break the compute embeddings method into separate methods:
  compute_image_embeddings and compute_metadata_embeddings

- If image_metadata_embeddings isn't defined, do not use it to enhance
  search results. Given image_metadata_embeddings wouldn't be defined
  if use_xmp_metadata is False, we can avoid unnecessary addition of
  args to query method
This commit is contained in:
Debanjum Singh Solanky
2021-09-16 12:01:05 -07:00
parent a4a23d7a72
commit 169ddcc8c6
4 changed files with 39 additions and 23 deletions

View File

@@ -57,7 +57,8 @@ default_config = {
'image':
{
'embeddings-file': '.image_embeddings.pt',
'batch-size': 50
'batch-size': 50,
'use-xmp-metadata': 'no'
},
'music':
{