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

dot falls back to LinearAlgebra/src/generic.jl #212

Open
rveltz opened this issue Jul 23, 2018 · 1 comment
Open

dot falls back to LinearAlgebra/src/generic.jl #212

rveltz opened this issue Jul 23, 2018 · 1 comment

Comments

@rveltz
Copy link

rveltz commented Jul 23, 2018

Hi,

I have another difficulty. It seems dot falls back to LinearAlgebra/src/generic.jl in both 0.7 and 0.6.4

Can it be fixed by?

import Base.LinAlg: dot, norm dot(a::ArrayFire.AFArray,b::ArrayFire.AFArray) = ArrayFire.dot(a,b,UInt32(0),UInt32(0))[1]

Also I had to extract the first element, it would be better for ArrayFire.dot to return a scalar.

Thank you

Best regards

@rveltz rveltz changed the title dot falls back to dot falls back to LinearAlgebra/src/generic.jl Jul 23, 2018
@rveltz
Copy link
Author

rveltz commented Jul 23, 2018

This dot function is giving me the error:

ERROR: ArgumentError: cannot convert NULL to string
Stacktrace:
 [1] unsafe_string at ./strings/string.jl:39 [inlined]
 [2] unsafe_string at ./c.jl:96 [inlined]
 [3] get_last_error() at /Users/rveltz/.julia/v0.6/ArrayFire/src/util.jl:299
 [4] _error(::UInt32) at /Users/rveltz/.julia/v0.6/ArrayFire/src/util.jl:86
 [5] dot(::ArrayFire.AFArray{Float64,1}, ::ArrayFire.AFArray{Float64,1}, ::UInt32, ::UInt32) at /Users/rveltz/.julia/v0.6/ArrayFire/src/wrap.jl:902
 [6] scope(::##39#40{ArrayFire.AFArray{Float64,1},ArrayFire.AFArray{Float64,1}}) at /Users/rveltz/.julia/v0.6/ArrayFire/src/scope.jl:40
 [7] dot(::ArrayFire.AFArray{Float64,1}, ::ArrayFire.AFArray{Float64,1}) at ./<missing>:0
 [8] (::##50#52{Float64,Int64,Int64,Bool,LinearMaps.FunctionMap{Float64,JacobianNF,Void},ArrayFire.AFArray{Float64,1}})() at /Users/rveltz/work/prog_gd/julia/dev/Continuation.jl/examples/../src/gmres-gpu.jl:105
 [9] scope(::##50#52{Float64,Int64,Int64,Bool,LinearMaps.FunctionMap{Float64,JacobianNF,Void},ArrayFire.AFArray{Float64,1}}) at /Users/rveltz/.julia/v0.6/ArrayFire/src/scope.jl:40
 [10] (::#kw##gmresGPU)(::Array{Any,1}, ::#gmresGPU, ::LinearMaps.FunctionMap{Float64,JacobianNF,Void}, ::ArrayFire.AFArray{Float64,1}, ::Int64) at ./<missing>:0

which seems like a bug in error handling

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

No branches or pull requests

1 participant