Skip to content

Ready to use configuration mlflow tracking server + local S3 storage based on Docker and Minio

Notifications You must be signed in to change notification settings

leoromanovich/mlflow_tracking_server

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

8 Commits
 
 
 
 
 
 
 
 

Repository files navigation

Ready to use configuration mlflow tracking server + local S3 storage based on Docker and Minio

Prerequisites:

For mlflow tracking server machine:

For client machine:

  • just install mlflow and boto3 libraries to your environment

It's possible to use the same machine as the server and the client

Configurations

Client and server are the same machine
Server on remote machine

Configuration Client and Server are the same machine

  1. Go to the directory, where your server will run and clone project
git clone https://github.com/leoromanovich/mlflow_tracking_server && cd mlflow_tracking_server
  1. Go to mlflow_server directory
cd mlflow_server
  1. Run server
sudo docker-compose up --build
  1. Server is ready, so add few lines to client code
  2. Check localhost:5555 for MLflow server and localhost:9001 for Minio
  3. Enjoy!

Configuration Server is remote machine

  1. Connect to your remote machine
  2. Go to the directory, where your server will run and clone project
git clone https://github.com/leoromanovich/mlflow_tracking_server && cd mlflow_tracking_server
  1. Go to mlflow_server directory
cd mlflow_server
  1. Run server
sudo docker-compose up --build
  1. Server is ready, so add few lines to client code

  2. Check your_server_ip:5555 for MLflow server and your_server_ip:9001

  3. Enjoy!

Client configuration

Add this lines to your experiment

import os
import mlflow

# Use IP of your remote machine here
# Don't change if client and server is the same machine
server_ip = '0.0.0.0'

os.environ['AWS_ACCESS_KEY_ID'] = 'minio'
os.environ['AWS_SECRET_ACCESS_KEY'] = 'minio123'
os.environ['MLFLOW_S3_ENDPOINT_URL'] = f'http://{server_ip}:9001'

mlflow.set_tracking_uri(f"http://{server_ip}:5555")
mlflow.set_experiment("awesome-experiment")

What if I want to change

  1. Aritfact-bucket and save artifacts there?

Open docker-compose.yml file and change all "mlflow-artifacts" entries to "new_bucket_name"

Acknowledgments

Mikhail Knyazev
Dmitry Kozlov
OCRV

About

Ready to use configuration mlflow tracking server + local S3 storage based on Docker and Minio

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published