0

I'm trying to run mlflow on Rstudio on win system. I install mlflow package using this command install.packages("mlflow"). And then I run the following code,

library(mlflow)

mlflow_ui()

This error is reported:

Error in wait_for(function() mlflow_rest("experiments", "search", client = client,  : 
  Operation failed after waiting for 10 seconds

I tried a few other command, like mlflow_log_metric("foo", 1). it's still the same error. I'm new to this package. Is there any way to fix this error? Thanks.

Harry
  • 331
  • 1
  • 4
  • 14
  • `traceback()` might give useful information. You might also check where you have all the packages dependencies. – IRTFM Jun 09 '23 at 18:38
  • @IRTFM I run traceback(), below is what returned. Cannot find where is the issue from. 6: stop("Operation failed after waiting for ", wait, " seconds") 5: wait_for(function() mlflow_rest("experiments", "search", client = client, verb = "POST", data = list(max_results = 1)), getOption("mlflow.connect.wait", 10), getOption("mlflow.connect.sleep", 1)) 4: mlflow_validate_server(client) 3: mlflow_client() 2: mlflow_ui.NULL() 1: mlflow_ui() I install all packages using the same command. Can you hint more on "where are packages dependencies"? Thanks. – Harry Jun 09 '23 at 23:38
  • Looks like there’s an attempt to access some via a POST operation and it’s failing. You should try to understand the package’s external (web) dependencies. – IRTFM Jun 10 '23 at 03:52
  • @IRTFM Thank you for your response. I'm new to this type of issue. I searched this manual "mlflow: R interface for MLflow", and followed it. But still cannot work. I searched for POST operations and packages external dependencies, but still cannot figure it out. Could you give a bit more hint on the root cause, or provide some link. Thanks in advance. – Harry Jun 12 '23 at 21:36
  • @IRTFM By the way, I installed mlflow python package, and I can run it using spyder or use python to call it inside terminal. However, I cannot run it from rstudio or call it using R from terminal. – Harry Jun 12 '23 at 21:38
  • @IRTFM This post gives me some hint. "https://stackoverflow.com/questions/60641337/mlflow-r-installation-mlflow-python-bin", it may be because the cluster in rstudio doesn't have outside connective privileges. I followed the method and set MLFLOW_BIN and MLFLOW_PYTHON_BIN with intern =TRUE. But still doesn't work. – Harry Jun 13 '23 at 00:29
  • I see you did some searching. I would not limit the search to SO but rather search with google. Alsio use `packageDescription("mlflow")` to see what "BugReports:" destination is recommended. When communicating with the `mlflow`-people you do a much better job of describing the entire process and your system setup. I cannot tell what system you are on and that is surely essential info. – IRTFM Jun 13 '23 at 01:58
  • @IRTFM Thank you for all the info. Super helpful! – Harry Jun 13 '23 at 03:43

0 Answers0