Skip to content
Snippets Groups Projects

Add an option to make the aggregate output unique

Merged Amir MOHAMMADI requested to merge unique into master

Merge request reports

Loading
Loading

Activity

Filter activity
  • Approvals
  • Assignees & reviewers
  • Comments (from bots)
  • Comments (from users)
  • Commits & branches
  • Edits
  • Labels
  • Lock status
  • Mentions
  • Merge request status
  • Tracking
  • Amir MOHAMMADI added 1 commit

    added 1 commit

    Compare with previous version

  • @pkorshunov I added a feature here which makes the lines unique in the aggregate output. This way you can iterate over all combinations but remove redundant lines in the end.

  • Thank you for this feature. I will check it out.

  • @pkorshunov I came with a yaml file like this eventually:

    # grid_search.yaml
    model:
      - {name: lenet_patch_whole_1,
         config: patch_estimator.py,
         patch_size: 28,
         n_filter_conv1: 32,
         n_filter_conv2: 32,
         n_units_dense1: 1000,
         image: whole_image}
    
    train:
      - {database: replaymobile, protocol: grandtest}
      - {database: uvad, protocol: experiment_1}
      - {database: replay, protocol: grandtest}
      - {database: oulunpu, protocol: Protocol_1}
    
    eval:
      - {database: replaymobile, protocol: grandtest, groups: ['dev', 'eval']}
      - {database: uvad, protocol: experiment_1, groups: ['dev', 'eval']}
      - {database: replay, protocol: grandtest, groups: ['dev', 'eval']}
      - {database: oulunpu, protocol: Protocol_1, groups: ['dev']}

    and I use it to generate the following template:

    # variables.py
    class AttrDict(dict):
        __getattr__ = dict.__getitem__
        __setattr__ = dict.__setitem__
    
    
    model = AttrDict({
        'name': '{{ model.name }}',
        'patch_size': '{{ model.patch_size }}',
    })
    train = AttrDict({
        'database': '{{ train.database }}',
        'protocol': '{{ train.protocol }}',
    })
    evaluation = AttrDict({
        'database': '{{ eval.database }}',
        'groups': '{{ eval.groups }}',
        'protocol': '{{ eval.protocol }}',
    })

    Then in the rest of my config files I can do:

    name = model.name
    ...
  • André Anjos mentioned in commit 43de8af2

    mentioned in commit 43de8af2

  • merged

Please register or sign in to reply
Loading