Skip to content
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

add_real_imag #1557

Merged
merged 5 commits into from
Sep 25, 2023
Merged

add_real_imag #1557

merged 5 commits into from
Sep 25, 2023

Conversation

vtavana
Copy link
Collaborator

@vtavana vtavana commented Sep 12, 2023

In this PR, we implement dpnp.real and dpnp.imag using their counterpart in dpctl, i.e., dpctl.tensor.real and dpctl.tensor.imag.

  • Have you provided a meaningful PR description?
  • Have you added a test, reproducer or referred to 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 filing the PR as a draft?

@vtavana vtavana self-assigned this Sep 12, 2023
@github-actions
Copy link
Contributor

github-actions bot commented Sep 12, 2023

View rendered docs @ https://intelpython.github.io/dpnp/index.html

@vtavana vtavana marked this pull request as ready for review September 13, 2023 00:33
dpnp/dpnp_algo/dpnp_elementwise_common.py Outdated Show resolved Hide resolved
dpnp/dpnp_algo/dpnp_elementwise_common.py Outdated Show resolved Hide resolved
dpnp/dpnp_array.py Outdated Show resolved Hide resolved
dpnp/dpnp_array.py Outdated Show resolved Hide resolved
dpnp/dpnp_iface_mathematical.py Outdated Show resolved Hide resolved
dpnp/dpnp_iface_mathematical.py Outdated Show resolved Hide resolved
dpnp/dpnp_iface_mathematical.py Outdated Show resolved Hide resolved
dpnp/dpnp_iface_mathematical.py Outdated Show resolved Hide resolved
dpnp/dpnp_iface_mathematical.py Outdated Show resolved Hide resolved
dpnp/dpnp_iface_mathematical.py Outdated Show resolved Hide resolved
Copy link
Collaborator

@vlad-perevezentsev vlad-perevezentsev left a comment

Choose a reason for hiding this comment

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

LGTM!
thank you @vtavana

dpnp/dpnp_array.py Show resolved Hide resolved
dpnp/dpnp_array.py Show resolved Hide resolved
@vtavana
Copy link
Collaborator Author

vtavana commented Sep 18, 2023

I had not paid attention to the fact that numpy.real and numpy.imag only accept one input. I have also modified the dpnp implementation to replicate this feature. Previous implementation could cause a problem when origin implementation ( call_origin ) was called.

@vlad-perevezentsev vlad-perevezentsev merged commit 329f36e into master Sep 25, 2023
32 of 33 checks passed
@vlad-perevezentsev vlad-perevezentsev deleted the real_imag_dpctl_to_dpnp branch September 25, 2023 13:30
@antonwolfy antonwolfy mentioned this pull request May 31, 2024
99 tasks
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