Skip to content

Enabled obb in Mosaic #219

Enabled obb in Mosaic

Enabled obb in Mosaic #219

Workflow file for this run

name: CI
on:
pull_request:
branches:
- main
paths-ignore:
- '**.md'
- 'benchmark/**'
push:
branches:
- main
paths-ignore:
- '**.md'
- 'benchmark/**'
jobs:
test_and_lint:
name: Test and lint
runs-on: ${{ matrix.operating-system }}
strategy:
matrix:
operating-system: [ubuntu-latest, windows-latest, macos-latest]
python-version: ["3.10", "3.11", "3.12", "3.13"]
fail-fast: true
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install uv and set Python version ${{ matrix.python-version }}
uses: astral-sh/setup-uv@v7
with:
enable-cache: true
python-version: ${{ matrix.python-version }}
activate-environment: true
- name: Install PyTorch
run: |
if [ "${{ matrix.operating-system }}" = "macos-latest" ]; then
uv pip install torch==2.7.1 torchvision==0.22.1
else
uv pip install torch==2.7.1+cpu torchvision==0.22.1+cpu --extra-index-url https://download.pytorch.org/whl/cpu
fi
shell: bash
- name: Install all dependencies
run: |
uv pip install wheel
uv pip install -r requirements-dev.txt
uv pip install .
- name: Run PyTest with coverage
run: pytest -n auto --cov=albumentations --cov-branch --cov-report=xml
- name: Upload coverage reports to Codecov
if: matrix.operating-system == 'ubuntu-latest' && matrix.python-version == '3.10'
uses: codecov/codecov-action@v5
with:
token: ${{ secrets.CODECOV_TOKEN }}
slug: albumentations-team/AlbumentationsX
files: ./coverage.xml
fail_ci_if_error: true
check_code_formatting_types:
name: Check code formatting with ruff and mypy
runs-on: ubuntu-latest
strategy:
fail-fast: true
matrix:
python-version: ["3.10"]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install uv and set Python version ${{ matrix.python-version }}
uses: astral-sh/setup-uv@v7
with:
enable-cache: true
python-version: ${{ matrix.python-version }}
activate-environment: true
- name: Install all requirements
run: |
uv pip install -r requirements-dev.txt
uv pip install .
- name: Run checks
run: pre-commit run --files $(find albumentations -type f)
- name: check-defaults-in-apply
run: python -m tools.check_defaults
check_transforms_docs:
name: Check Readme is not outdated
runs-on: ubuntu-latest
strategy:
matrix:
python-version: ["3.10"]
steps:
- name: Checkout
uses: actions/checkout@v4
- name: Install uv and set Python version ${{ matrix.python-version }}
uses: astral-sh/setup-uv@v7
with:
enable-cache: true
python-version: ${{ matrix.python-version }}
activate-environment: true
- name: Install all requirements
run: |
uv pip install opencv-python-headless>=4.9.0.80 requests
uv pip install .
- name: Run checks for documentation
run: python -m tools.make_transforms_docs check README.md