-
Notifications
You must be signed in to change notification settings - Fork 15
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
#1036: Added pytorch and numba integration test compatible with CPU only VM #485
Conversation
''')) | ||
|
||
row = self.query(f"SELECT pytorchbasic.test_pytorch(1000);")[0] | ||
self.assertIn('Mean Squared Error', row[0]) |
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 would assert if the loss is not NaN, this could hint to something is broken, if it worked before
/ | ||
''')) | ||
|
||
row = self.query("SELECT numbabasic.test_numba(10000);")[0] |
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.
Is it necessary to verify the returned value?
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.
We should simply out of good practice
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 think not. The return value is some random number. If there is any problem, an exception is thrown and this breaks the test.
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.
In that case your are assert should be , did we get a row back
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.
Added an assert for the resulting row
/ | ||
''')) | ||
|
||
row = self.query(f"SELECT pytorchbasic.test_pytorch(1000);")[0] | ||
self.assertIn('Mean Squared Error', row[0]) | ||
|
||
self.assertFalse(math.isnan(row[0])) |
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 think, NaN is transformed to NULL in the DB
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.
Appearantly the build failed when fetching micromamba. Running the test locally , the assert is correct.
Return the sum of the discrimants and check number
related exasol/script-languages-release#1036