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

Maximising inheritance: Conform to BIDS 1.x #4

Open
5 tasks
Lestropie opened this issue May 3, 2024 · 0 comments
Open
5 tasks

Maximising inheritance: Conform to BIDS 1.x #4

Lestropie opened this issue May 3, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@Lestropie
Copy link
Owner

Extension of #2.

If it is possible for a data file to have any number of applicable metadata files at any level of the filesystem hierarchy, then the algorithm for determining the optimal placement of metadata fields in terms of filesystem level & entity set is relatively simple: each metadata value can simply be promoted up the hierarchy / have entities stripped as much as is possible.

However in BIDS 1.x, this is not actually permitted. For any given data file, there can be no more than one metadata file applicable at any given filesystem level.

Creating an algorithm that will both maximally exploit the Inheritance Principle, and obey this restriction, will I think actually be considerably more difficult than #2.

Here's one possibility:

  • For each filesystem level (from highest to lowest):
    • Until there is no longer any opportunity to exploit inheritance at this filesystem level:
      • For every possible combination of entities:
        • Compute how many metadata field values could possibly be placed into that metadata file that would result in appropriate inheritance
      • Create metadata file with set of entities that resulted in the maximal number of metadata fields being placed within it

It's not necessary a globally optimal solution, but it might be adequate.

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

No branches or pull requests

1 participant