N3PDF / vegasflow

VegasFlow: accelerating Monte Carlo simulation across multiple hardware platforms
https://vegasflow.readthedocs.io
Apache License 2.0
34 stars 9 forks source link

Cuda example #52

Closed scarlehoff closed 4 years ago

scarlehoff commented 4 years ago

While rehearsing the presentation for ICHEP I realized it would be a nice touch to have a Cuda integrand example. Need to modify the makefile so it can compiled both by default but only if nvcc is present.

Rant: how is the Tensorflow documentation for custom operators so terribly bad??!?!? It's not only badly explained and hard to understand. That's fine. But the first header is called kernel_example.h, two files down it has changed to example.h? And then by the time they explain how to compile it the name has changed from kernel_example to cuda_op_kernel? Is there nobody revising the stuff they write? Good god.

scarlehoff commented 4 years ago

btw, together with this example I've brought some of the stuff from pdfflow like the logger and hiding away the warnings form tensorflow.

scarlehoff commented 4 years ago

It's mainly so I can say "you can find a cuda example in the repository" during the talk :P