Skip to content

Commit

Permalink
Add gpu vs cpu results comparison
Browse files Browse the repository at this point in the history
  • Loading branch information
luisaforozco committed Jun 19, 2024
1 parent 0e9cb49 commit 9ab56d2
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions examples/src/test_derivatives.jl
Original file line number Diff line number Diff line change
Expand Up @@ -414,6 +414,12 @@ else
println("[GPU] ERROR: Some methods produce different results")
end

if all(results[1] Array(result) for result in results_GPU[2:end])
println("[GPU vs CPU] All methods produce the same results")
else
println("[GPU vs CPU] ERROR: Some methods produce different results")
end

# sort the results by time
methods_gpu = []
times_gpu = []
Expand Down

0 comments on commit 9ab56d2

Please sign in to comment.