aim icon indicating copy to clipboard operation
aim copied to clipboard

Add support for setting Run name via Run.__init__

Open vakker opened this issue 2 years ago • 7 comments

🐛 Bug

When I set the run_hash manually I get:

Setting custom `Run.hash` value is deprecated! Consider setting `Run.name` instead. This functionality will be removed in version 3.15.

To reproduce

aim.Run(experiment="asd", run_hash="potato")

Expected behavior

The warning is clear per se, however the fix is not. It comes from here. The Run class doesn't have a name property, nor a parameter to its __init__. Am I missing something?

Environment

  • Aim Version: v3.13.3
  • Python version: 3.9.7

vakker avatar Sep 21 '22 22:09 vakker

Hey @vakker! Adding the name argument to Run.__init__ will resolve the issue. Meanwhile, can you try to set the name right after creating Run instance?

run = aim.Run(experiment="asd")
run.name = "potato"

alberttorosyan avatar Sep 22 '22 06:09 alberttorosyan

Yeah, setting it after the init works. But then is it used anywhere? The Run class doesn't seem to use the name property anywhere.

vakker avatar Sep 22 '22 08:09 vakker

@vakker the Run.name is displayed in UI (see attached screenshot), as well as can be used to filter runs, metrics when doing queries: run.name == "my run" and metric.context.subset == "train"

Screen Shot 2022-09-22 at 14 25 19

alberttorosyan avatar Sep 22 '22 10:09 alberttorosyan

as for the setting the name via __init__, could you please change the issue description accordingly? alternative would be to submit the new feature request and close this one.

alberttorosyan avatar Sep 22 '22 10:09 alberttorosyan

@alberttorosyan thanks, that makes sense. I can change the description, but to what exactly?

vakker avatar Sep 22 '22 13:09 vakker

Hey @vakker! Sorry for late response; somehow missed your last comment. I think something like this would be a good match: Add support for setting Run name via Run.__init__

alberttorosyan avatar Oct 04 '22 06:10 alberttorosyan

Hi @SGevorg, We have developed this features internally that user can choose the optional run name Run(name='my-run') or by setting env variable export __AIM_RUN_NAME__=my-run If no one has started the development, we can plan to move the changes to this repo. Thanks

sharathmk9 avatar Dec 26 '23 11:12 sharathmk9