SubstantialElk6 if you call Task.init with continue_last_task=<task_id> it will automatically add the last_iteration of the previous run, to any logging/report so you never overwrite the previous reports 🙂
Just to put a ping for those on this side of the timezone to look at. Thanks.
Hi, for both of them, args.lastiter
 is the exact same value. But when plotted out, they are 2 actually iterations apart.
So you mean args.lastiter
is not the last iteration? Can you try replacing it with task.get_last_iteration()
?
Hi,
basically i run this block first and ended the script.task = Task.init(project_name="afro-nmt", task_name=args.taskname, continue_last_task=args.taskid) Logger.current_logger().report_scalar(title="BLEU",series="JW300",value=args.jwbleu, iteration=args.lastiter)
Then i run another script, with series different.task = Task.init(project_name="afro-nmt", task_name=args.taskname, continue_last_task=args.taskid) Logger.current_logger().report_scalar(title="BLEU",series="SS900",value=args.ssbleu, iteration=args.lastiter)
Didnt get that, can you detail a bit?
It didn't work as expected.
` task init
task report iter 10
task init
task report iter 10
The second task pushed the reporting iteration to 20 instead. `
Hi SubstantialElk6 , you can use task.get_last_iteration()
and use it, what do you think?
Hi TimelyPenguin76 , i am adding a debug sample to an existing task using the above method. What should i put for the iteration? I do not want to overwrite existing ones but i do not know what's the last count. This is for both scalar and media reporting.
Thanks TimelyPenguin76 , let me try it out now.
Hi SubstantialElk6
If you like a new task, you can clone as HugePelican43 suggested.
You can also continue reporting to your task with continue_last_task
parameter in your Task.init
call:
from clearml import Task task = Task.init(project_name="YOUR PROJECT NAME", task_name="YOUR TASK NAME", continue_last_task=True)
You also can specify the task id to continue (from the docs - https://allegro.ai/clearml/docs/rst/references/clearml_python_ref/task_module/task_task.html?highlight=continue_last_task ):
continue_last_task ( bool ) –
Continue the execution of a previously executed Task (experiment)
Note
When continuing the executing of a previously executed Task, all previous artifacts / models/ logs are intact. New logs will continue iteration/step based on the previous-execution maximum iteration value. For example:
The last train/loss scalar reported was iteration 100, the next report will be iteration 101.
The values are:True
- Continue the the last Task ID. specified explicitly by reuse_last_task_id or implicitly with the same logic as reuse_last_task_id False
- Overwrite the execution of previous Task (default). A string - You can also specify a Task ID (string) to be continued. This is equivalent to continue_last_task=True and reuse_last_task_id=a_task_id_string.