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
Sub process logger #482
Comments
Hi @ophirazulai,
Can you share the code that does that?
Using ClearML Agent? |
Hi @jkhenning I can only share snippets Process A (Training):
Process B (Inference) - no ClearML agentfrom clearml import Task Can it be that something is passed in the system variables ? Maybe a quick fix will be to override it |
OK, but what does |
It is internal IBM job scheduler that simply starts new process on a different computer. Can it be that something is passed in the system variables ? Maybe a quick fix will be to override it |
What I'm not sure is how you start a new process on the other machine - what do you provide to the ClearML Task.init(), how do you provide the |
The IBM job scheduler start a new process on a different computer. The job is submitted on my name so I guess the clearml.conf is taken from my home directory. In process B |
It's possible the new task reuses your current task - you can try passing |
Tried that already, didn't help |
Well, than - it's important to understand exactly how the new process is created - is that a fork? or something is copied (and then - what command-line is executed?) |
It is not my code, I don't know. Does your code uses any environment variables ? That I can override, this seems the only way process B can know about process A. |
ClearML can use environment variables, but the question remains how process B is executed... How are you running process A? Did you manually start the task with some IDE or python command? |
I run task A exactly as task B. Submit new job in the IBM internal job scheduler. Is there environment variable that if it exists, then the logs continue to session in this environment variable ? |
Can you try to unset the |
Yes! :-) will update |
Tried to unset CLEARML_PROC_MASTER_ID and it didn't help. Tried two ways: and In process B Here is an example code: import sys import copyprint("os.os.environ = ") if 'CLEARML_PROC_MASTER_ID' in os.environ: |
Hi @ophirazulai , In your example code, when do you import clearml? before or after this code? |
First lines in the script. |
Also tried to close the task before sending the job and then re-open it. Here is the code:
|
Can you try to unset |
This solved the problem, thanks a lot for your support |
Great 🙂 I'm closing the issue, please ping here if required. |
Hi,
Here is the description of the problem:
I have process A who creates logger using this command:
task = Task.init(project_name=args.clearml_proj_base + “/training”, task_name=args.clearml_task,
tags=[args.loss,‘patch size’ + str(args.patch_size), str(args.num_features)+‘’+str(args.max_features)+‘’+str(args.unet_depth) , ‘two channels’, ‘lr_default’],
continue_last_task=False)
logger = task.get_logger()
Then this process submit new job/process B (for inference) in our cluster and this job runs on a different computer.
The new job creates logger using:
task = Task.init(project_name=project_name, task_name=task_name)
or
task = Task.init(project_name=project_name, task_name=task_name, continue_last_task=False, reuse_last_task_id = False)
or
task = Task.init(project_name=project_name, task_name=task_name, continue_last_task=False)
Different project_name and task_name.
The problem is that all of B logs are created in the A task.
Also there is no entry for the new project_name/task_name.
Thanks,
Ophir Azulai
IBM Research AI
The text was updated successfully, but these errors were encountered: