Spaces:
Build error
Build error
Download include/CL/Utils/Event.hpp from kristada673/WizardCoder: direct link, hf CLI and curl.
- Browser
- Download file 462 Bytes
-
https://huggingface.co/spaces/kristada673/WizardCoder/resolve/main/include/CL/Utils/Event.hpp
- Command line
-
hf download hf://spaces/kristada673/WizardCoder/include/CL/Utils/Event.hpp
-
curl -L -o Event.hpp https://huggingface.co/spaces/kristada673/WizardCoder/resolve/main/include/CL/Utils/Event.hpp
462 Bytes
| // OpenCL SDK includes | |
| // STL includes | |
| // OpenCL includes | |
| namespace cl { | |
| namespace util { | |
| template <cl_int From, cl_int To, typename Dur = std::chrono::nanoseconds> | |
| auto get_duration(cl::Event& ev) | |
| { | |
| return std::chrono::duration_cast<Dur>(std::chrono::nanoseconds{ | |
| ev.getProfilingInfo<To>() - ev.getProfilingInfo<From>() }); | |
| } | |
| } | |
| } | |