Skip to content

impl elementwise hyperbolic and trigonometric functions #1234

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 11 commits into from
Jul 25, 2023

Conversation

vtavana
Copy link
Collaborator

@vtavana vtavana commented Jun 7, 2023

In this PR. the following elementwise functions are implemented and tested: dpctl.tensor.acos, dpctl.tensor.acosh, dpctl.tensor.asin, dpctl.tensor.asinh, dpctl.tensor.atan, dpctl.tensor.atanh, dpctl.tensor.cosh, dpctl.tensor.tanh, dpctl.tensor.tan, and dpctl.tensor.tanh. dpctl.tensor.cos and dpctl.tensor.sin are also modified to handle special cases for complex numbers correctly.

  • 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?

@vtavana vtavana self-assigned this Jun 7, 2023
@github-actions
Copy link

github-actions bot commented Jun 7, 2023

@github-actions
Copy link

github-actions bot commented Jun 7, 2023

Array API standard conformance tests for dpctl=0.14.3dev3=py310h7bf5fec_16 ran successfully.
Passed: 399
Failed: 601
Skipped: 119

@vtavana vtavana force-pushed the elementwise-hyper-and-trig-funcs branch from 94c6b6c to 36a084f Compare June 7, 2023 17:50
@github-actions
Copy link

github-actions bot commented Jun 7, 2023

Array API standard conformance tests for dpctl=0.14.3dev3=py310h7bf5fec_16 ran successfully.
Passed: 399
Failed: 601
Skipped: 119

@vtavana vtavana force-pushed the elementwise-hyper-and-trig-funcs branch 2 times, most recently from caf503d to b6597ff Compare June 20, 2023 16:55
@vtavana vtavana marked this pull request as ready for review June 20, 2023 16:56
@github-actions
Copy link

Array API standard conformance tests for dpctl=0.14.4=py310h7bf5fec_8 ran successfully.
Passed: 466
Failed: 534
Skipped: 119

@vtavana vtavana force-pushed the elementwise-hyper-and-trig-funcs branch from b6597ff to dac0a26 Compare July 17, 2023 13:53
@vtavana vtavana force-pushed the elementwise-hyper-and-trig-funcs branch from dac0a26 to 739ea9e Compare July 17, 2023 13:59
@coveralls
Copy link
Collaborator

coveralls commented Jul 17, 2023

Coverage Status

coverage: 83.244% (+0.03%) from 83.218% when pulling 2f5a453 on elementwise-hyper-and-trig-funcs into 73a2b68 on master.

@github-actions
Copy link

Array API standard conformance tests for dpctl=0.14.5dev1=py310h7bf5fec_11 ran successfully.
Passed: 527
Failed: 473
Skipped: 119

@oleksandr-pavlyk
Copy link
Contributor

Lots of RuntimeError: Required aspect fp64 is not supported on the device when running on Iris Xe.

@github-actions
Copy link

Array API standard conformance tests for dpctl=0.14.6dev0=py310h7bf5fec_12 ran successfully.
Passed: 553
Failed: 447
Skipped: 119

Removed explicit uses of double type constants in direct and inverse
trigonometric and hyperbolic functions.

Updated tests as needed.
Using `np.float32(X)` call generates X.size single-element device-to-host
transfers and is very slow.
@oleksandr-pavlyk
Copy link
Contributor

Lots of RuntimeError: Required aspect fp64 is not supported on the device when running on Iris Xe.

UPD: This has all been addressed.

@github-actions
Copy link

Array API standard conformance tests for dpctl=0.14.6dev0=py310h7bf5fec_16 ran successfully.
Passed: 554
Failed: 446
Skipped: 119

@oleksandr-pavlyk oleksandr-pavlyk force-pushed the elementwise-hyper-and-trig-funcs branch from e26cc3e to 183817a Compare July 21, 2023 20:13
@github-actions
Copy link

Array API standard conformance tests for dpctl=0.14.6dev0=py310h7bf5fec_32 ran successfully.
Passed: 554
Failed: 446
Skipped: 119

@github-actions
Copy link

Array API standard conformance tests for dpctl=0.14.6dev0=py310h7bf5fec_34 ran successfully.
Passed: 554
Failed: 446
Skipped: 119

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.

This PR looks good to me. Please wait for other reviewers to provide their feedback though.

Copy link
Collaborator

@ndgrigorian ndgrigorian left a comment

Choose a reason for hiding this comment

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

This LGTM. Thank you @vtavana and @oleksandr-pavlyk it's great to see these array API conformance numbers jump up

@vtavana vtavana merged commit 9380514 into master Jul 25, 2023
@vtavana vtavana deleted the elementwise-hyper-and-trig-funcs branch July 25, 2023 20:36
@github-actions
Copy link

Deleted rendered PR docs from intelpython.github.com/dpctl, latest should be updated shortly. 🤞

@github-actions
Copy link

Array API standard conformance tests for dpctl=0.14.6dev0=py310h7bf5fec_38 ran successfully.
Passed: 556
Failed: 444
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.

4 participants