diff --git a/cpp/ViolaJones.hpp b/cpp/ViolaJones.hpp index ed663cb..b525fa9 100644 --- a/cpp/ViolaJones.hpp +++ b/cpp/ViolaJones.hpp @@ -9,7 +9,7 @@ template bool unit_test_cpu_vs_gpu(const np::Array& cpu, const np::Array& gpu) noexcept { if (cpu.shape != gpu.shape) { #if __DEBUG - fprintf(stderr, "Inequal shape !\n"); + fprintf(stderr, "Unequal shape !\n"); #endif return false; } @@ -32,7 +32,7 @@ template bool unit_test_argsort_2d(const np::Array& a, const np::Array& indices) noexcept { if (a.shape != indices.shape) { #if __DEBUG - fprintf(stderr, "Inequal shape !\n"); + fprintf(stderr, "Unequal shape !\n"); #endif return false; } @@ -60,8 +60,8 @@ T benchmark_function(const char* step_name, const F& fnc, Args &&...args) noexce #endif const std::chrono::system_clock::time_point start = perf_counter_ns(); const T res = fnc(std::forward(args)...); - const long long timespent = duration_ns(perf_counter_ns() - start); - printf("| %-49s | %18s | %-29s |\n", step_name, thousand_sep(timespent).c_str(), format_time_ns(timespent).c_str()); + const long long time_spent = duration_ns(perf_counter_ns() - start); + printf("| %-49s | %18s | %-29s |\n", step_name, thousand_sep(time_spent).c_str(), format_time_ns(time_spent).c_str()); return res; } @@ -73,8 +73,8 @@ void benchmark_function_void(const char* step_name, const F& fnc, Args &&...args #endif const std::chrono::system_clock::time_point start = perf_counter_ns(); fnc(std::forward(args)...); - const long long timespent = duration_ns(perf_counter_ns() - start); - printf("| %-49s | %18s | %-29s |\n", step_name, thousand_sep(timespent).c_str(), format_time_ns(timespent).c_str()); + const long long time_spent = duration_ns(perf_counter_ns() - start); + printf("| %-49s | %18s | %-29s |\n", step_name, thousand_sep(time_spent).c_str(), format_time_ns(time_spent).c_str()); } template diff --git a/cpp/data.hpp b/cpp/data.hpp index 29c2c7a..464e43a 100644 --- a/cpp/data.hpp +++ b/cpp/data.hpp @@ -534,7 +534,7 @@ namespace np { // bool Array::operator==(const Array& other) const noexcept { // if (shape != other.shape) // return false; - // const size_t lenght = np::prod(shape); + // const size_t length = np::prod(shape); // for(size_t i = 0; i < length; ++i) // if (data[i] != other[i]) // return false;