Skip to content
This repository was archived by the owner on Jul 22, 2024. It is now read-only.
This repository was archived by the owner on Jul 22, 2024. It is now read-only.

How to make it work with Azure Databricks - MLFlow #7

@jannavarro

Description

@jannavarro

In Azure Databricks, MLFlow is supported and can be accessed via API. The MS docs says:

You can invoke the MLflow REST API using URLs of the form https://<databricks-instance>/api/2.0/mlflow/<api-endpoint>, replacing <databricks-instance> with the <region>.azuredatabricks.net domain name of your Azure Databricks deployment.

So in my appsettings.json I have:

{
  "MLFlowConfiguration": {
    "MLFlowServerBaseUrl": "https://southeastasia.azuredatabricks.net",
    "APIBase": "api/2.0/mlflow/"
  }
}

But trying that with the lines of code below returns an exception:

var experimentName = Guid.NewGuid().ToString();
var experimentRequest = await _mlFlowService.GetOrCreateExperiment(experimentName);

Error:
'Object reference not set to an instance of an object.'

   at MLFlow.NET.Lib.Services.MLFlowService.<GetOrCreateExperiment>d__4.MoveNext()
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()
   at MLNETMLFlowSampleConsole.Program.<RunExperiment>d__3.MoveNext() in C:\Samples\2019\MLNETMLFlowSample\MLNETMLFlowSampleConsole\Program.cs:line 55
   at System.Runtime.ExceptionServices.ExceptionDispatchInfo.Throw()
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.GetResult()
   at MLNETMLFlowSampleConsole.Program.<Main>d__2.MoveNext() in C:\Samples\2019\MLNETMLFlowSample\MLNETMLFlowSampleConsole\Program.cs:line 34

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions