Skip to content

feat: allow passing validation set explicitly #245

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 6 commits into from
May 22, 2025

Conversation

JarbasAl
Copy link
Contributor

@JarbasAl JarbasAl commented May 21, 2025

i have been experimenting with model2vec and it is great! kudos for the awesome work

I wanted to use my own validation set but that was not exposed, this PR simply adds optional arguments to the fit method to allow passing your own validation data

Copy link
Member

@stephantul stephantul left a comment

Choose a reason for hiding this comment

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

This looks good, thanks for the PR. I can see that you didn't run pre-commit on this. Could you make the necessary changes and then run pre-commit before you commit?

@JarbasAl
Copy link
Contributor Author

JarbasAl commented May 21, 2025

This looks good, thanks for the PR. I can see that you didn't run pre-commit on this. Could you make the necessary changes and then run pre-commit before you commit?

sorry, i never used pre-commit before, i installed it and ran it before the last commit i pushed but it doesn't seem to have done anything?

$ pre-commit
[WARNING] Unstaged files detected.
[INFO] Stashing unstaged files to /home/miro/.cache/pre-commit/patch1747854475-1318277.
check python ast.....................................(no files to check)Skipped
trim trailing whitespace.............................(no files to check)Skipped
fix end of files.....................................(no files to check)Skipped
check for added large files..........................(no files to check)Skipped
check for case conflicts.............................(no files to check)Skipped
check yaml...........................................(no files to check)Skipped
pydoclint............................................(no files to check)Skipped
ruff.................................................(no files to check)Skipped
ruff-format..........................................(no files to check)Skipped
mypy.................................................(no files to check)Skipped
[INFO] Restored changes from /home/miro/.cache/pre-commit/patch1747854475-1318277.

not sure what is supposed to happen here

@stephantul
Copy link
Member

No worries, I can show you. From your output, I see you haven't staged the files, or have already pushed them. You can run make install from the root of the project, this will install and run pre-commit as a hook whenever you run git commit. This should make it block you from committing stuff that doesn't pass the pre-commit checks. Let me know if that works.

@JarbasAl
Copy link
Contributor Author

i don't think my pycharm install is liking pre-commit...

I can have a look later if that is a blocker for the PR and I'll redo it from scratch without pycharm in the mix

The other requested changes have been pushed

@stephantul
Copy link
Member

@JarbasAl , I added some more validation and tests, and ran the pre-commit. The tests are failing because of some unrelated transformers issue. Feel free to take a look if you like the changes.

@stephantul stephantul self-requested a review May 22, 2025 08:36
Copy link
Member

@stephantul stephantul left a comment

Choose a reason for hiding this comment

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

@JarbasAl Looks good, thanks for the contribution!

@stephantul
Copy link
Member

The lates commits are to fix the failing CI

@JarbasAl
Copy link
Contributor Author

awesome, thanks for wrapping this up!

awesome project and super responsive and helpful devs, what else could anyone ask for :)

@stephantul stephantul merged commit af6f67c into MinishLab:main May 22, 2025
6 checks passed
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.

2 participants