-
Notifications
You must be signed in to change notification settings - Fork 43
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
Fixes for test_training.py failures #245
Fixes for test_training.py failures #245
Conversation
Here is an example of a CI job which fails partly because of the
Full details (click to expand)
|
Codecov Report
@@ Coverage Diff @@
## dev #245 +/- ##
======================================
Coverage ? 38.34%
======================================
Files ? 30
Lines ? 3987
Branches ? 0
======================================
Hits ? 1529
Misses ? 2458
Partials ? 0 📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more |
The CI passes now, hooray! 🎉 🎉 |
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.
Thanks @GenevieveBuckley.
This looks good and I will merge this now so that we can go ahead with the rest.
Eventually we should add a few more unit-tests for the device handling and update the type annotations so that both strs and torch devices are allowed. I will take care of this later.
4561969
into
computational-cell-analytics:dev
We've been seeing CI failures related to the
test_training.py
script.I've investigated, and found:
device
variable to be a string (eg:"cpu"
,"cuda"
, or"mps"
), but the training script had it set as a PyTorch objectdevice = torch.device(type="cpu")
.This PR addresses both issues. Most lines of code relate to problem 2.
pytest test/test_training.py
now passes locally on my machine. The CI job should run the tests for this branch once I submit the PR.