Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
29 changes: 29 additions & 0 deletions .github/workflows/CI.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,29 @@
name: CI

on: pull_request

permissions:
contents: read

jobs:
test:
name: CI Python ${{ matrix.python-version }}
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10", "3.11", "3.12", "3.13"]
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Install uv and set Python
uses: astral-sh/setup-uv@v5
with:
python-version: ${{ matrix.python-version }}
enable-cache: true
cache-dependency-glob: "uv.lock"
- name: Sync dependencies
run: uv sync --locked --all-extras --dev
- name: Run pre-commit
run: uv run pre-commit run --all-files
- name: Run tests
run: uv run pytest tests
9 changes: 9 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
.vscode/
.venv
__pycache__
.mypy_cache/
.pytest_cache/
.ruff_cache/
.coverage
.coverage.*
.ablate
13 changes: 13 additions & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
repos:
- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.11.8
hooks:
- id: ruff
args: [--fix]
- id: ruff-format
- repo: https://github.com/codespell-project/codespell
rev: v2.4.1
hooks:
- id: codespell
additional_dependencies:
- tomli
1 change: 1 addition & 0 deletions .python-version
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
3.10
1 change: 1 addition & 0 deletions README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
# ablate
1 change: 1 addition & 0 deletions ablate/__init__.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
__version__ = "0.1.0"
88 changes: 88 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,88 @@
[project]
name = "ablate"
version = "0.1.0"
description = "ablate"
authors = [{ name = "Simon Rampp", email = "simon@rampp.dev" }]
license = { text = "MIT" }
readme = "README.md"
requires-python = ">=3.10"
keywords = [
"machine learning",
"deep learning",
"experiment tracking",
"reporting",
"markdown",
"CLI",
]

dependencies = [
"matplotlib>=3.10.3",
"pandas>=2.2.3",
"pydantic>=2.11.4",
"seaborn>=0.13.2",
"tabulate>=0.9.0",
"tomli>=2.2.1",
]

[dependency-groups]
dev = [
"codespell>=2.4.1",
"pre-commit==4.2.0",
"pytest>=8.3.5",
"pytest-cov>=6.1.1",
"ruff==0.11.8",
]

[build-system]
requires = ["hatchling"]
build-backend = "hatchling.build"

[project.scripts]
ablate = "ablate.core.cli.main:main"

[project.optional-dependencies]
mlflow = ["mlflow>=2.22.0"]

[tool.ruff]
line-length = 88
target-version = "py310"

[tool.ruff.format]
docstring-code-format = true

[tool.ruff.lint]
select = [
"F",
"E",
"W",
"I",
"N",
"Q",
"ANN",
"BLE",
"B",
"C4",
"ISC",
"ICN",
"LOG",
"G",
"PYI",
"PT",
"RET",
"SIM",
"TC",
"ERA",
]
ignore = ["E741", "N812", "N806", "N802", "ANN401"]

[tool.ruff.lint.isort]
known-first-party = ["ablate"]
force-sort-within-sections = true
lines-after-imports = 2

[tool.pytest.ini_options]
addopts = "--cov=ablate --cov-report=term-missing"
testpaths = "tests"

[tool.codespell]
skip = "uv.lock"
9 changes: 9 additions & 0 deletions tests/test_version.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import tomli

import ablate


def test_version() -> None:
with open("pyproject.toml", "rb") as f:
pyproject = tomli.load(f)
assert pyproject["project"]["version"] == ablate.__version__
2,055 changes: 2,055 additions & 0 deletions uv.lock

Large diffs are not rendered by default.