-
Notifications
You must be signed in to change notification settings - Fork 2
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
Improved packaging and CI pipeline for lighter #17
Conversation
I see you included #14, but that hasn't been merged yet, just a heads up. I will get back to that PR today or tomorrow. |
@ibro45 Work in progress for now, will merge all effective branches when this goes in at the end |
Before I merge this, it would be great if you both @ibro45 @kbressem could test the following,
I will resolve the errors for the builds and we can also check if the tests run as expected. |
I discussed with Suraj in private about this, we found a solution, but @kbressem did you not have it? |
@ibro45 So the keyring happens only on certain systems where there is secure keyring installed. If you tested it on our machines in Boston, you should have this issue. But not all systems have this, for example, machines running the CI do not have this issue. @kbressem Will add version to the init! Thanks for pointing out. I also think mypy should be out of the install loop, fixing |
@Keno The version string should be available now. We can bump versions with the command, @ibro45 The console scripts does not work as expected yet, doing |
@ibro45 Will wait for you to merge the logger and I can re-submit this for review to be merged then. Ideally we need someone to test this in a fresh environment and see if all functionality works as expected |
Ready for review and verification from your side to merge. I've added an integration test as well to check if something would break on PRs Very simple test for now, will add more functionality and clean it up once we have this addressed Project-MONAI/MONAI#5899 I will create another issue for a potential suite of tests |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To be honest, I do not even understand half of the poetry configs, so I cannot check if everything is correct. But overall it looks really good and all configurations seem reasonable and well thought through.
I will install the library again in a fresh environment and then finish this review.
trainer#max_steps: 5 | ||
trainer#num_sanity_val_steps: 0 | ||
trainer#accelerator: cpu | ||
system#batch_size: 16 | ||
system#num_workers: 2 | ||
trainer#callbacks: null |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To reduce testing time, we should simplify the tests and only focus on testing if the code runs.
Additionally, we could implement slower tests that run for multiple epochs with a fixed seed. These tests will ensure that the metrics remain consistent, indicating that the code is functioning correctly and the network trains correctly. But such a test will take several minutes and is annoying if you want to just add a simple PR.
trainer#max_steps: 5 | |
trainer#num_sanity_val_steps: 0 | |
trainer#accelerator: cpu | |
system#batch_size: 16 | |
system#num_workers: 2 | |
trainer#callbacks: null | |
trainer#max_steps: 2 | |
trainer#num_sanity_val_steps: 0 | |
trainer#accelerator: cpu | |
system#batch_size: 4 | |
system#num_workers: 2 | |
trainer#callbacks: null |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I agree! We should have two sets of tests. One that runs by default on PR and then another that we can trigger manually when we want to merge more breaking changes (this will be the longer multiple epoch ones).
For the latter, pytest
provides some nice functionality to tag tests with different markers. If you see the integration test here:
lighter/tests/integration/test_cifar.py
Line 13 in 5d02775
@pytest.mark.slow |
I've marked it as slow. We can set pytest markers for each of the two sets accordingly and run them as we need
I am also still getting used to poetry but having someone test the functionality is what we need at this point. I think we can figure deeper concepts as we go then |
Test: #24 Everything went smoothly. Approving, and a reminder for PyPi. |
Sounds good! I'd skip everything except the folders that we use for demos, right now it's only cifar10 |
@surajpaib seems like |
Yes. Just removing it worked for me (see also #24). Also, I had to first uninstall poetry before I could reinstall it. Maybe we can add |
Removing Poetry has an issue where it breaks if the secure keyring is enabled. I've tried to use the fix mentioned in the issue. For now, it only works for bash. We'll need to see what to do if people have different shells and have the keyring enabled. I'll work on a long-term fix for our repo for this. But maybe in a different issue. @kbressem Agree with adding poetry remove! Will do so. Maybe even a full cleanup so everytime setup is run, its a fresh install |
Just something that came to my mind, gotta check it later, but writing it here not to forget - when cloning |
Actually, it'd make more sense if it's another package that'd be installed like |
No description provided.