Skip to content
Snippets Groups Projects
Commit d72a9c42 authored by Erik Frisk's avatar Erik Frisk
Browse files

small update

parent b85a77a9
Branches
Tags
No related merge requests found
#include <iostream>
#include <nanobind/nanobind.h>
#include <nanobind/ndarray.h>
#include <nanobind/stl/vector.h>
......@@ -18,14 +17,12 @@ array_sum_nocopy(const nb::ndarray<double> &a)
{
const auto p = a.data();
return std::accumulate(p, p + a.size(), 0.0);
// return 0.0;
}
double
array_sum(const std::vector<double> &a)
{
return std::accumulate(a.begin(), a.end(), 0.0);
// return 0.0;
}
NB_MODULE(my_ext, m)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment