Rearranging columns in guild compare

Hi there!

First off, thanks a lot for making Guild!

I was wondering if there is a way to rearrange the columns in guild compare? It seems like by default the scalars come after the flags whereas I’d like for it to be the other way round.

Second, I’m noticing that if I use guild compare -cc followed by a comma-separated list of column names which include both flags and scalars, only the scalars get outputted correctly; the values for the flag columns are empty.

FWIW I’m on Guild version 0.7.1:

% pip freeze | grep guildai                                                                                                                               20-12-08 - 14:26:45
guildai==0.7.1

EDIT: here is a quick example to reproduce things.

Here’s my toy guild.yml file:

- operations:
    quick_example:
      description: "Quick example"
      exec: "echo \"Loss: 0.123\""
      flags:
        log_file:
          type: string
          default: "example.log"
      output-scalars:
        - loss: 'Loss: (\value)'

If I run guild run quick_example and then guild_compare, I see

However, if I run guild compare -cc log_file,loss I get

image

Thanks a lot in advance!
jks

To show flags in a column listing you need to prefix the name with =. E.g. guild compare -cc loss,=log_file.

In your Guild file, specify the columns you want in order using the operation compare attribute like this:

# guild.yml

quick_example:
  ...
  compare:
    - last loss step as step
    - loss
    - =log_file

Unfortunately there’s no way to generalize the order to place flags after scalars. This configuration is all per operation.

Thank you @garrett! This seems to be what I needed – per-operation configuation should be just fine.

1 Like