Share via

In AzureML, start_logging will start asynchronous execution or synchronous execution?

Mo Zein 1 Reputation point
2022-08-08T18:21:44.493+00:00

It was written in the Microsoft AzureML documentation, "A run represents a single trial of an experiment. Runs are used to monitor the asynchronous execution of a trial" and A Run object is also created when you submit or start_logging with the Experiment class."

Related to start_logging, as far as I know, when we have simply started the run by executing this start logging method. We have to stop, or complete by complete method when the run is completed. This is because start_logging is a synchronized way of creating an experiment. However, Run object created from start_logging is to monitor the asynchronous execution of a trial.

Can anyone clarify whether start_logging will start asynchronous execution or synchronous execution?

Azure Machine Learning

1 answer

Sort by: Most helpful
  1. Rohit Mungi 49,131 Reputation points Microsoft Employee Moderator
    2022-08-09T06:55:25.043+00:00

    @Mo Zein start_logging will create a run object similar to experiment.submit() but in the case of start_logging you can create an interactive logging session and create an interactive run in the specified experiment and in either case, the logging methods on the returned run object work the same.

    For example,

    run = exp.start_logging() #Will give you the context of run object directly  
    run_id = run.id # access the run id for use later  
    
    Run = experiment.submit()   
    run = Run.get_context() #To access the current run context of your code  
    

    I think this notebook explains the usage of logging better in this context.

    If an answer is helpful, please click on 130616-image.png or upvote 130671-image.png which might help other community members reading this thread.

    Was this answer helpful?

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.