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

Improve trace.txt linking to results #446

Open
rcannood opened this issue Apr 27, 2024 · 0 comments
Open

Improve trace.txt linking to results #446

rcannood opened this issue Apr 27, 2024 · 0 comments
Labels
enhancement New feature or request

Comments

@rcannood
Copy link
Member

Right now, the trace.txt uses the tag which is simply set to $id to figure out which process is linked to which component. However, the structure of the id is highly dependant on the task and component being run, as different steps will add on extra info to the id. Example, a predict modality metric: openproblems_neurips2022/pbmc_multiome/normal/log_cp10k.guanlab_dengkw_pm.correlation.


I'd be useful if methods and metrics could have their tag set to something that is machine interpretable, e.g. a json {"dataset_id": ..., "normalization_id": ..., ...}. Fundamentally, it would probably be a good idea to implement this at a Viash level, so we can do something like:

| component.run(
  auto: [
    tag: { id, state ->
      toJsonBlob([dataset_id: state.dataset_id])
    }
  ]
)

However, perhaps there is something we can already do right now. The issue is that the tag is currently limited to the information that the underlying process has access to, namely:

input: tuple val(id), path(viash_par_input_mod1), path(viash_par_mod2), val(args), path(resourcesDir)

In here, id is self-explanatory, input_mod1 and input_mod2 correspond to input files used by the component, and args are all other arguments a component has.

That's why we are able to use tag: "$id". I suppose that doesn't leave much room for other arguments, unless we add an optional name: --tag, type: string argument to all methods and metrics so that we can use them for setting tag: "${args.tag ?: id}".

@KaiWaldrant WDYT?

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