arrayfire / arrayfire-rust

Rust wrapper for ArrayFire
BSD 3-Clause "New" or "Revised" License
810 stars 58 forks source link

[BUG] FFT example not working, Trait Bound HasAfEnum not implemented for Complex<float> #331

Closed steckes closed 1 year ago

steckes commented 1 year ago

Can not run the fft example: the trait HasAfEnum is not implemented for Complex<{f64}>.

Using:

The documentation of this library is saying that HasAfEnum is implemented for Complex< f32 > and Complex< f64 >.

Screenshot 2022-08-08 at 14 52 53
cavemanloverboy commented 1 year ago

I'm also seeing this

9prady9 commented 1 year ago

@stexa Please see the implementations here https://github.com/arrayfire/arrayfire-rust/blob/89528902409a849ee92c982d19024789112e510c/src/core/util.rs#L210-L241.

I am unable to reproduce this using master branch. Are you noticing this with release version of crate or master branch ?

9prady9 commented 1 year ago

@stexa Is still an active issue on your end ?

steckes commented 1 year ago

It is resolved! Was not working with 3.8 from crates.io, but it is working when adding arrayfire from git master branch. [dependencies] arrayfire = { git = "https://github.com/arrayfire/arrayfire-rust" } num = "0.4.0"

9prady9 commented 1 year ago

It is resolved! Was not working with 3.8 from crates.io, but it is working when adding arrayfire from git master branch. [dependencies] arrayfire = { git = "https://github.com/arrayfire/arrayfire-rust" } num = "0.4.0"

Thanks for clarifying, I will try to push our a new crate soon. Sorry about the inconvenience.