Skip to content
Closed
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
11 changes: 11 additions & 0 deletions .github/workflows/mkdocs-build.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
name: MkDocs Build (RationAI Standard)
on:
push:
branches: ["master"]
pull_request:
branches: ["master"]
workflow_dispatch:

jobs:
run:
uses: RationAI/.github/.github/workflows/mkdocs-build.yml@main
11 changes: 11 additions & 0 deletions .github/workflows/python-lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
name: Python Lint (RationAI Standard)
on:
push:
branches: ["master"]
pull_request:
branches: ["master"]
workflow_dispatch:

jobs:
run:
uses: RationAI/.github/.github/workflows/python-lint.yml@main
9 changes: 0 additions & 9 deletions .gitlab-ci.yml

This file was deleted.

6 changes: 6 additions & 0 deletions .markdownlint.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,6 @@
MD013: false # Line length
MD023: false # Heading start left
MD024: false # Duplicate headings
MD033: false # Inline HTML
MD041: false # First line in file should be a top level heading
MD046: false # Fenced code blocks
6 changes: 5 additions & 1 deletion .mypy.ini
Original file line number Diff line number Diff line change
Expand Up @@ -3,4 +3,8 @@ strict = True
ignore_missing_imports = True
disallow_untyped_calls = False
disable_error_code = no-any-return
explicit_package_bases = True
explicit_package_bases = True

# Ignore type errors in the external piqe.py file
[mypy-rationai.qc.focus.piqe]

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

high

The module name is incorrectly specified as rationai.qc.focus.piqe instead of rationai.qc.blur.piqe. Since the file is located at rationai/qc/blur/piqe.py, the correct module path is rationai.qc.blur.piqe. Because of this mismatch, mypy will not correctly ignore errors in the intended file.

[mypy-rationai.qc.blur.piqe]

ignore_errors = True
9 changes: 4 additions & 5 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -8,16 +8,15 @@ repos:
args: [--unsafe]

- repo: https://github.com/commitizen-tools/commitizen
rev: v4.8.3
rev: v4.10.0
hooks:
- id: commitizen

- repo: https://github.com/astral-sh/ruff-pre-commit
rev: v0.12.10
rev: v0.14.10
hooks:
# Run the linter.
- id: ruff
entry: pdm lint --force-exclude
- id: ruff-check
args: [--fix]
# Run the formatter.
- id: ruff-format
entry: pdm format --force-exclude
8 changes: 5 additions & 3 deletions .ruff.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,8 @@ fix = true
line-length = 88
target-version = "py311"

extend-exclude = ["rationai/qc/blur/piqe.py"]

[format]
# Enable reformatting of code snippets in docstrings.
docstring-code-format = true
Expand All @@ -20,10 +22,10 @@ extend-select = [
"PGH", # pygrep
"RUF", # ruff checks
"SIM", # flake8-simplify
"TCH", # flake8-type-checking
"TC", # flake8-type-checking
"TID", # flake8-tidy-imports
"UP", # pyupgrade
"D", # pydocstyle
"D", # pydocstyle
]
extend-ignore = [
"ERA001", # commented out code
Expand All @@ -36,7 +38,7 @@ extend-ignore = [
"D106", # missing docstring in public nested class
"D107", # missing docstring in __init__
"N812", # lowercase imported as non lowercase
"TCH002", # move third-party into a type-checking block
"TC002", # move third-party into a type-checking block
"F722", # jaxtyping
]

Expand Down
19 changes: 18 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,4 +5,21 @@ for QC methods** developed at RationAI. These functions are meant to be run on s
regions and they **offer a straightforward and well-documented access** to the key parts
of the complete QC methods to allow for easier debugging and experimenting.

TODO: Add link to mkdocs documentation
## Documentation

**[`RationAI Quality Control`](https://rationai.github.io/quality-control/)**

## Setting up a Development Environment

1. Create the development environment (including all optional and development dependencies):

```bash
uv sync --all-groups
```

2. Install pre-commit hooks:

```bash
uv run pre-commit install
uv run pre-commit install --hook-type commit-msg
```
31 changes: 5 additions & 26 deletions docs/getting-started/installation.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
1. ### Install **pyvips** for Efficient Image Processing
1. ### Install **pyvips** for Efficient Image Processing

[Pyvips](https://pypi.org/project/pyvips/2.0.2/) is a powerful and fast image processing library, particularly suited for working with large images like WSIs. To install `pyvips`, ensure that the `libvips` system dependencies are installed first:

Expand All @@ -18,41 +18,20 @@

Follow the instructions on the official [libvips installation page](https://www.libvips.org/install.html).


2. ### Install the Core Quality Control Library
2. ### Install the Core Quality Control Library

You can install the core library using one of the following methods, depending on your package manager:

=== "pdm"

```bash
pdm add git+https://gitlab.ics.muni.cz/rationai/digital-pathology/quality-control/quality-control.git
```

=== "pip"

```bash
pip install git+https://gitlab.ics.muni.cz/rationai/digital-pathology/quality-control/quality-control.git
```

#### Installing a Specific Version

To install a specific version of the **Quality Control** library, use the following command, replacing `v1.0.0` with your desired version.

=== "pdm"
=== "uv"

```bash
pdm add git+https://gitlab.ics.muni.cz/rationai/digital-pathology/quality-control/quality-control.git@v1.0.0
uv add git+https://github.com/RationAI/quality-control.git
```

=== "pip"

```bash
pip install git+https://gitlab.ics.muni.cz/rationai/digital-pathology/quality-control/quality-control.git@v1.0.0
pip install git+https://github.com/RationAI/quality-control.git
```

!!! info

Replace `v1.0.0` with the specific version you want to install.

Once **pyvips**, and the core library are installed, you're ready to start using QC functions.
Loading
Loading