Skip to content

Changes to elementwise function tests that use complex data types #1412

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 4 commits into from
Sep 21, 2023

Conversation

ndgrigorian
Copy link
Collaborator

@ndgrigorian ndgrigorian commented Sep 20, 2023

This PR simplifies the test_[func]_out_overlap testing for elementwise funcs in dpctl by removing most of these tests, which were redundant, leaving only a test for overlap in test_abs.py.

This PR also modifies pyproject.toml and conftest.py to add a new pytest marker and complementary option, broken_complex, which skips some tests by default due to known issues on some platforms (esp. Windows).

  • Have you provided a meaningful PR description?
  • Have you added a test, reproducer or referred to an issue with a reproducer?
  • Have you tested your changes locally for CPU and GPU devices?
  • Have you made sure that new changes do not introduce compiler warnings?
  • Have you checked performance impact of proposed changes?
  • If this PR is a work in progress, are you opening the PR as a draft?

@github-actions
Copy link

@coveralls
Copy link
Collaborator

coveralls commented Sep 20, 2023

Coverage Status

coverage: 85.774%. remained the same when pulling 39a48e1 on fix-elementwise-tests-complex into 9a1f205 on master.

@oleksandr-pavlyk
Copy link
Contributor

If the other PR where elementwise tess were added, I skipped these test only on windows. Can it be supported?

@ndgrigorian
Copy link
Collaborator Author

If the other PR where elementwise tess were added, I skipped these test only on windows. Can it be supported?

I've pushed a change that should do just that.

@ndgrigorian ndgrigorian force-pushed the fix-elementwise-tests-complex branch from c0b253f to 8cdc736 Compare September 21, 2023 01:26
@github-actions
Copy link

Array API standard conformance tests for dpctl=0.15.0rc1=py310ha25a700_3 ran successfully.
Passed: 916
Failed: 84
Skipped: 119

Also rewrote overlap test for abs to only use a single dtype
…a types on some platforms

The marker "broken_complex" can be used to skip these broken tests.

Running the tests with `pytest --runcomplex` permits running the test.
@github-actions
Copy link

Array API standard conformance tests for dpctl=0.15.0rc1=py310ha25a700_4 ran successfully.
Passed: 916
Failed: 84
Skipped: 119

1 similar comment
@github-actions
Copy link

Array API standard conformance tests for dpctl=0.15.0rc1=py310ha25a700_4 ran successfully.
Passed: 916
Failed: 84
Skipped: 119

@ndgrigorian ndgrigorian force-pushed the fix-elementwise-tests-complex branch from 8cdc736 to af7fea1 Compare September 21, 2023 02:48
@github-actions
Copy link

Array API standard conformance tests for dpctl=0.15.0rc1=py310ha25a700_10 ran successfully.
Passed: 916
Failed: 84
Skipped: 119

@ndgrigorian ndgrigorian force-pushed the fix-elementwise-tests-complex branch from af7fea1 to 39a48e1 Compare September 21, 2023 04:09
@github-actions
Copy link

Array API standard conformance tests for dpctl=0.15.0rc1=py310ha25a700_10 ran successfully.
Passed: 916
Failed: 84
Skipped: 119

@ndgrigorian ndgrigorian marked this pull request as ready for review September 21, 2023 16:47
pyproject.toml Outdated
@@ -33,6 +33,9 @@ omit = [
]

[tool.pytest.ini.options]
markers = [
"broken_complex: mark a test that is skipped due to complex implementation",
Copy link
Contributor

Choose a reason for hiding this comment

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

Suggested change
"broken_complex: mark a test that is skipped due to complex implementation",
"broken_complex: mark a test that is skipped on Windows due to complex implementation",

Copy link
Contributor

@oleksandr-pavlyk oleksandr-pavlyk left a comment

Choose a reason for hiding this comment

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

Module a nit in the description of broken_complex marker, this is good. Thank you @ndgrigorian

"on Windows" added to make it clear that this marker only skips for Windows platforms
@ndgrigorian ndgrigorian merged commit 1f34c0d into master Sep 21, 2023
@ndgrigorian ndgrigorian deleted the fix-elementwise-tests-complex branch September 21, 2023 20:03
@github-actions
Copy link

Array API standard conformance tests for dpctl=0.15.0rc1=py310ha25a700_13 ran successfully.
Passed: 916
Failed: 84
Skipped: 119

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.

3 participants