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

Fix python API + small fixes #32

Open
wants to merge 3 commits into
base: master
Choose a base branch
from
Open

Conversation

s-mandra
Copy link

Python API is not working properly for complex arrays (see issue #31).

There is also an issue in benchmark/reference.cpp when floating point are passed to std::conj. std::conj tries to convert floating point to complex number, raising an error at lines 60 and 67. Fixed by creating a new conj function that return the same object if not a complex number (otherwise, it calls std::conj).

For the handles cTensorTranspose and zTensorTranspose removed the __Complex keyword (variables are re-casted to either FloatComplex and DoubleComplex anyway).

@s-mandra
Copy link
Author

s-mandra commented Feb 16, 2023

Tested with g++-12, clang-9 and clang-13 on linux.

@ultimatile
Copy link

ultimatile commented May 16, 2023

Regarding the fix for issue #21, how about using an explicit type conversion like hptt::DoubleComplex(__real__ alpha, __imag__ alpha) instead of (hptt::DoubleComplex) alpha?
Is it better to remove the __Complex keyword?

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.

None yet

3 participants