Logging in Python SDK

Michael Schmidt 280 Reputation points
2024-12-16T13:59:10.6133333+00:00

Hi,

I ask whether these differences exist in the Python SDK between logging in training and logging after deployment:

https://learn.microsoft.com/en-us/azure/machine-learning/how-to-track-experiments-mlflow?view=azureml-api-2

"The Azure Machine Learning Python SDK v2 does not provide native logging or tracking capabilities. This applies not just for logging but also for querying the metrics logged. Instead, use MLflow to manage experiments and runs."

https://learn.microsoft.com/en-us/azure/machine-learning/how-to-collect-production-data?view=azureml-api-2&tabs=azure-cli

"Data collection with custom logging allows you to log pandas DataFrames directly from your scoring script before, during, and after any data transformations. With custom logging, tabular data is logged in real time to your workspace Blob Storage or a custom blob storage container. Your model monitors can consume the data from storage."

Or do I misunderstand sth.?

Bye

Michael

Azure Machine Learning
Azure Machine Learning
An Azure machine learning service for building and deploying models.
3,042 questions
{count} votes

1 answer

Sort by: Most helpful
  1. Avinash Devarakonda 525 Reputation points Microsoft Vendor
    2024-12-17T06:31:08.57+00:00

    Hi Michael Schmidt,

    Welcome to Microsoft Q&A Forum, thank you for posting your query here!

    The Azure Machine Learning Python SDK v2 does not provide built-in logging capabilities for training or post-deployment scenarios. Instead:

    During training, MLflow is used to log models, metrics, parameters, and artifacts. This allows you to effectively track experiments, compare results, and manage different runs.

    After deployment, custom logging can be implemented to capture model input and output data. This helps monitor model behavior and performance.

    Although the approaches are different, both methods play a crucial role in tracking, analyzing, and improving the overall performance of machine learning models.

    You can consider document as reference for Log metrics, parameters, and files with MLflow.


    I'm glad to hear that my response was helpful to you. And thanks for sharing the information, which might be beneficial to other community members reading this thread as solution. Since the Microsoft Q&A community has a policy that "The question author cannot accept their own answer. They can only accept answers by others ", so I'll convert the previous response to an answer in case you'd like to accept the answer. This will help other users who may have a similar query find the solution more easily. If you have any further questions or concerns, please don't hesitate to ask. We're always here to help.

    1 person found this answer helpful.
    0 comments No comments

Your answer

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