Skip to content

refactor: migration and tooling#3

Closed
TomasBalak wants to merge 12 commits into
masterfrom
refactor/migration-and-tooling
Closed

refactor: migration and tooling#3
TomasBalak wants to merge 12 commits into
masterfrom
refactor/migration-and-tooling

Conversation

@TomasBalak

Copy link
Copy Markdown
Collaborator

Migrating from GitLab to GitHub (1/6)

Overview

This PR contains the following changes:

  • Migration from GitLab to GitHub
  • Tooling updates
  • Installation guide updates
  • Small fixes to docs and linting

Merge Order

master
  └── 1️⃣ refactor/migration-and-tooling
        └── 2️⃣ refactor/staining-api-update
              └── 3️⃣ refactor/deprecated-skimage-api
                    └── 4️⃣ refactor/output-schema-unification
                          └── 5️⃣ fix/folding-improvements
                                └── 6️⃣ chore/docs-and-cleanup

Out of the 6 PRs containing the latest features and changes, this one needs to be merged first.

@TomasBalak TomasBalak self-assigned this Jun 9, 2026
@coderabbitai

coderabbitai Bot commented Jun 9, 2026

Copy link
Copy Markdown

Important

Review skipped

Draft detected.

Please check the settings in the CodeRabbit UI or the .coderabbit.yaml file in this repository. To trigger a single review, invoke the @coderabbitai review command.

⚙️ Run configuration

Configuration used: defaults

Review profile: CHILL

Plan: Pro

Run ID: 5b75d714-0ade-40ff-abfa-e2543dcc5be4

You can disable this status message by setting the reviews.review_status to false in the CodeRabbit configuration file.

Use the checkbox below for a quick retry:

  • 🔍 Trigger review
✨ Finishing Touches
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Commit unit tests in branch refactor/migration-and-tooling

Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

Code Review

This pull request migrates the project's dependency management and development environment setup from PDM to UV, updates documentation and configuration files accordingly, and adds exclusions for an external PIQE module. While the changes are a great step forward, several issues were identified in the documentation and configuration. Specifically, there is an incorrect module path in .mypy.ini, a Python 3.11 syntax error in the documentation's f-string examples, a variable name mismatch causing a NameError, and outdated parameter descriptions for the folding function. Additionally, the git sources in pyproject.toml should be updated to point to GitHub instead of GitLab.

Important

The consumer version of Gemini Code Assist on GitHub is being sunset. Starting June 18, 2026, new organization installations will be blocked, and all code review activity will officially cease on July 17, 2026.
For more details on the timeline and next steps, please review the Help Documentation.

Comment thread .mypy.ini
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]

Comment on lines +61 to +62
print(f"Number of flagged pixels: {artifacts["number_of_flagged_pixels"]}")
print(f"Number of examined pixels: {artifacts["number_of_examined_pixels"]}")

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

In Python 3.11 (which is the target version specified in .ruff.toml), nesting double quotes inside a double-quoted f-string results in a SyntaxError. Please use single quotes for the dictionary keys to ensure compatibility with Python 3.11.

Suggested change
print(f"Number of flagged pixels: {artifacts["number_of_flagged_pixels"]}")
print(f"Number of examined pixels: {artifacts["number_of_examined_pixels"]}")
print(f"Number of flagged pixels: {artifacts['number_of_flagged_pixels']}")
print(f"Number of examined pixels: {artifacts['number_of_examined_pixels']}")



img = np.asarray(Image.open("fold.png").conver("RGB")) # Investigated image
img = np.asarray(Image.open("fold.png").convert("RGB")) # Investigated image

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

There is a mismatch in the variable name used for the local area image. On line 208, it is defined as local_area_image =img_area = ... (which also lacks a space around the = operator), but on lines 218 and 228, local_area_img is used. This will cause a NameError when running the example. Please update line 208 to define local_area_img directly:

local_area_img = np.asarray(Image.open("fold_area.png").convert("RGB")) # Local area of investigated image

Comment on lines +232 to +233
The `level_downsample argument` is the downsample rate between the highest resolution level and the level from which the image was taken.
`nuclues_diameter_at_base_level` specifies the nucleus diameter at the highest resolution level (it can be easily measured when browsing the WSI).

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

The description refers to non-existent parameters level_downsample and nuclues_diameter_at_base_level (which also has a typo) for the folding function. The actual parameters are mpp and cell_nucleus_size. Please update the documentation to describe the correct parameters.

Comment thread pyproject.toml
Comment on lines +22 to +23
rationai-masks = { git = "https://gitlab.ics.muni.cz/rationai/digital-pathology/libraries/masks.git" }
rationai-staining = { git = "https://gitlab.ics.muni.cz/rationai/digital-pathology/libraries/staining.git" }

Copy link
Copy Markdown

Choose a reason for hiding this comment

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

medium

Since this PR is migrating the project from GitLab to GitHub, the git sources for rationai-masks and rationai-staining should also be updated to point to their new GitHub repository URLs under the RationAI organization, rather than continuing to reference GitLab.

@TomasBalak TomasBalak closed this Jun 9, 2026
@TomasBalak TomasBalak deleted the refactor/migration-and-tooling branch June 9, 2026 14:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant