audeering / audb

Manage audio and video databases
https://audeering.github.io/audb/
Other
23 stars 1 forks source link

audb.load_to() does not load all attachments #313

Closed hagenw closed 4 weeks ago

hagenw commented 1 year ago

If a database has several attachments (in this case all attached as folders, haven't checked the case of single files yet), and is loaded with audb.load_to('build/', ...) it might happen that not all attachments are loaded.

Assume the following entry in the db.yaml header:

attachments:
  a-a: {description: 'Attachment a-a', path: a/a/}
  a-b: {description: 'Attachment a-b', path: a/b/}
  b-a: {description: 'Attachment b', path: b/a/}
  c-a: {description: 'Attachment c', path: c/a/}

The expected directory tree of the attachments after loading them would be:

build/
  a/
    a/
      file-a-a-1
      file-a-a-2
    b/
      file-a-b-1
      file-a-b-2
  b/
    a/
      file-b-a-1
      file-b-a-2
  c/
    a/
      file-c-a-1
      file-c-a-2

Instead what we get is

build/
  a/
    a/
      file-a-a-1
      file-a-a-2
    b/
      file-a-b-1
      file-a-b-2

So it is only loading two of the four attachments.

hagenw commented 1 year ago

I tested with num_workers=8 and num_workers=1, result is the same.

hagenw commented 1 month ago

I tried to replicate this error in https://github.com/audeering/audb/pull/421, but did not suceed.