Skip to content

Commit

Permalink
Merge pull request #40 from neptune-ai/aw/update-integration
Browse files Browse the repository at this point in the history
Update MLflow integration
  • Loading branch information
AleksanderWWW authored Jun 21, 2023
2 parents 49198e5 + 1d80316 commit e700b83
Show file tree
Hide file tree
Showing 41 changed files with 1,087 additions and 592 deletions.
26 changes: 26 additions & 0 deletions .github/actions/e2e/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
---
name: Test E2E
description: Run e2e tests
inputs:
working_directory:
description: "Working directory"
required: false
default: .
runs:
using: "composite"
steps:
- name: Checkout
uses: actions/checkout@v2
with:
repository: neptune-ai/neptune-mlflow
path: ${{ inputs.working_directory }}

- name: Install dependencies
working-directory: ${{ inputs.working_directory }}
run: pip install -e .[dev]
shell: bash

- name: Run tests
working-directory: ${{ inputs.working_directory }}
run: pytest -v tests/e2e
shell: bash
26 changes: 26 additions & 0 deletions .github/actions/unit/action.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
---
name: Unit test
description: Run unit tests
inputs:
working_directory:
description: "Working directory"
required: false
default: .
runs:
using: "composite"
steps:
- name: Checkout
uses: actions/checkout@v2
with:
repository: neptune-ai/neptune-mlflow
path: ${{ inputs.working_directory }}

- name: Install dependencies
working-directory: ${{ inputs.working_directory }}
run: pip install -e .[dev]
shell: bash

- name: Run tests
working-directory: ${{ inputs.working_directory }}
run: pytest -v tests/unit
shell: bash
79 changes: 79 additions & 0 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
name: neptune-mlflow
on: [push]
jobs:
pre-commit:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2

- uses: actions/setup-python@v2
with:
python-version: 3.9

- name: Install dependencies
run: |
pip install -e .[dev]
- name: Pre-commit
run: |
pre-commit run --show-diff-on-failure --color=always
e2e:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macos-latest, windows-latest]
python-version: [3.9]
steps:
- uses: actions/checkout@v2

- uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}

- name: Test
env:
NEPTUNE_API_TOKEN: ${{ secrets.E2E_NEPTUNE_API_TOKEN }}
NEPTUNE_PROJECT: e2e-tests/e2e
uses: ./.github/actions/e2e

unit:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ ubuntu-latest, macos-latest, windows-latest ]
python-version: [ 3.9 ]
steps:
- uses: actions/checkout@v2

- uses: actions/setup-python@v2
with:
python-version: ${{ matrix.python-version }}

- name: Test
uses: ./.github/actions/unit

publish:
needs: [pre-commit, e2e, unit]
runs-on: ubuntu-latest
if: github.event_name == 'push' && startsWith(github.ref, 'refs/tags')
steps:
- uses: actions/checkout@v2

- uses: actions/setup-python@v2
with:
python-version: 3.9

- name: Install build dependencies
run: pip install poetry poetry-dynamic-versioning

- name: Build package
run : |
poetry build
- name: Publish package
uses: pypa/[email protected]
with:
user: __token__
password: ${{ secrets.PYPI_API_TOKEN }}
packages_dir: dist
19 changes: 0 additions & 19 deletions .github/workflows/pre-commit.yml

This file was deleted.

7 changes: 7 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -107,3 +107,10 @@ venv.bak/

# Pycharm
.idea/

# MLflow
mlruns/
test_tracking_uri/

# Neptune
.neptune/
20 changes: 0 additions & 20 deletions .travis.yml

This file was deleted.

4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
## [UNRELEASED] neptune-mlflow 1.0.0

### Changes
- Updated MLflow exporter to work with the current neptune.ai API ([#40](https://github.com/neptune-ai/neptune-mlflow/pull/40))
3 changes: 0 additions & 3 deletions MANIFEST.in

This file was deleted.

13 changes: 0 additions & 13 deletions Makefile

This file was deleted.

3 changes: 0 additions & 3 deletions docs_requirements.txt

This file was deleted.

58 changes: 0 additions & 58 deletions git_version.py

This file was deleted.

77 changes: 77 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,3 +1,77 @@
[build-system]
requires = ["poetry-core>=1.0.0", "poetry-dynamic-versioning"]
build-backend = "poetry_dynamic_versioning.backend"

[tool.poetry-dynamic-versioning]
enable = true
vcs = "git"
style = "semver"
pattern = "default-unprefixed"

[tool.poetry.dependencies]
python = "^3.7"

# Python lack of functionalities from future versions
importlib-metadata = { version = "*", python = "<3.8" }

mlflow = ">=1.24.0"
# dev
pre-commit = { version = "*", optional = true }
pytest = { version = ">=5.0", optional = true }
pytest-cov = { version = "2.10.1", optional = true }
neptune = { version = ">=1.0.0", optional = true }
tensorflow = { version = ">2.0.0", optional = true }

[tool.poetry.extras]
dev = [
"pre-commit",
"pytest",
"pytest-cov",
"neptune",
"tensorflow",
]

[tool.poetry]
authors = ["neptune.ai <[email protected]>"]
description = "neptune.ai MLflow integration library"
repository = "https://github.com/neptune-ai/neptune-mlflow"
homepage = "https://neptune.ai/"
documentation = "https://docs.neptune.ai/integrations/mlflow/"
include = ["CHANGELOG.md"]
license = "Apache License 2.0"
name = "neptune-mlflow"
readme = "README.md"
version = "0.0.0"
classifiers = [
"Development Status :: 4 - Beta",
"Environment :: Console",
"Intended Audience :: Developers",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: Apache Software License",
"Natural Language :: English",
"Operating System :: MacOS",
"Operating System :: Microsoft :: Windows",
"Operating System :: POSIX",
"Operating System :: Unix",
"Topic :: Software Development :: Libraries :: Python Modules",
"Programming Language :: Python :: Implementation :: CPython",
"Topic :: Scientific/Engineering :: Artificial Intelligence",
]
keywords = [
"MLOps",
"ML Experiment Tracking",
"ML Model Registry",
"ML Model Store",
"ML Metadata Store",
]
packages = [
{ include = "neptune_mlflow_exporter", from = "src" },
]

[tool.poetry.urls]
"Tracker" = "https://github.com/neptune-ai/neptune-mlflow/issues"
"Documentation" = "https://docs.neptune.ai/integrations/mlflow/"

[tool.black]
line-length = 120
target-version = ['py37', 'py38', 'py39', 'py310']
Expand All @@ -21,3 +95,6 @@ force_grid_wrap = 2
[tool.flake8]
max-line-length = 120
extend-ignore = "E203"

[tool.poetry.plugins."neptune.plugins"]
"mlflow" = "neptune_mlflow_exporter:sync"
6 changes: 0 additions & 6 deletions requirements.txt

This file was deleted.

2 changes: 0 additions & 2 deletions setup.cfg

This file was deleted.

Loading

0 comments on commit e700b83

Please sign in to comment.