Skip to content

feat(train and test sets): expose the paths to save train and test sets during L2G training#1217

Open
project-defiant wants to merge 9 commits into
opentargets:devfrom
project-defiant:dev
Open

feat(train and test sets): expose the paths to save train and test sets during L2G training#1217
project-defiant wants to merge 9 commits into
opentargets:devfrom
project-defiant:dev

Conversation

@project-defiant
Copy link
Copy Markdown
Contributor

@project-defiant project-defiant commented Apr 17, 2026

✨ Context

This PR adds the option to save the train and test sets from L2G training step.

🛠 What does this PR implement

  • Add handlers to save train and test sets in the L2G Training
  • Exposes training_set and test_set parameters to L2G Step configuration

🙈 Missing

🚦 Before submitting

  • Do these changes cover one single feature (one change at a time)?
  • Did you read the contributor guideline?
  • Did you make sure to update the documentation with your changes?
  • Did you make sure there is no commented out code in this PR?
  • Did you follow conventional commits standards in PR title and commit messages?
  • Did you make sure the branch is up-to-date with the dev branch?
  • Did you write any new necessary tests?
  • Did you make sure the changes pass local tests (make test)?
  • Did you make sure the changes pass pre-commit rules (e.g uv run pre-commit run --all-files)?

Copilot AI and others added 9 commits April 16, 2026 16:48
Agent-Logs-Url: https://github.com/project-defiant/gentropy/sessions/d3ed16a9-ec3a-489d-a781-09465517c733

Co-authored-by: project-defiant <69353402+project-defiant@users.noreply.github.com>
Agent-Logs-Url: https://github.com/project-defiant/gentropy/sessions/d3ed16a9-ec3a-489d-a781-09465517c733

Co-authored-by: project-defiant <69353402+project-defiant@users.noreply.github.com>
Agent-Logs-Url: https://github.com/project-defiant/gentropy/sessions/d3ed16a9-ec3a-489d-a781-09465517c733

Co-authored-by: project-defiant <69353402+project-defiant@users.noreply.github.com>
Agent-Logs-Url: https://github.com/project-defiant/gentropy/sessions/d3ed16a9-ec3a-489d-a781-09465517c733

Co-authored-by: project-defiant <69353402+project-defiant@users.noreply.github.com>
Agent-Logs-Url: https://github.com/project-defiant/gentropy/sessions/628d56e4-bddc-407a-bd56-2d70bf371deb

Co-authored-by: project-defiant <69353402+project-defiant@users.noreply.github.com>
Agent-Logs-Url: https://github.com/project-defiant/gentropy/sessions/628d56e4-bddc-407a-bd56-2d70bf371deb

Co-authored-by: project-defiant <69353402+project-defiant@users.noreply.github.com>
Agent-Logs-Url: https://github.com/project-defiant/gentropy/sessions/628d56e4-bddc-407a-bd56-2d70bf371deb

Co-authored-by: project-defiant <69353402+project-defiant@users.noreply.github.com>
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR extends the L2G (locus-to-gene) training step configuration so callers can optionally persist the generated train/test splits as parquet outputs during model training.

Changes:

  • Added training_set and test_set output-path fields to LocusToGeneConfig.
  • Wired training_set/test_set through LocusToGeneStep and implemented pandas-based parquet persistence after training.
  • Added a config test asserting the new config fields exist.

Reviewed changes

Copilot reviewed 3 out of 3 changed files in this pull request and generated 3 comments.

File Description
src/gentropy/config.py Adds training_set and test_set fields to LocusToGeneConfig so they can be provided via structured config.
src/gentropy/l2g.py Passes through new config params and writes train/test split pandas DataFrames to parquet when paths are provided.
tests/gentropy/test_config.py Adds a unit test to ensure the new config fields are exposed on LocusToGeneConfig.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Comment thread src/gentropy/l2g.py
Comment thread src/gentropy/l2g.py
Comment thread src/gentropy/l2g.py
@project-defiant project-defiant self-assigned this Apr 21, 2026
@project-defiant project-defiant added the enhancement New feature or request label Apr 21, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants