ext/torch/templates.hpp in torch-rb-0.1.8 vs ext/torch/templates.hpp in torch-rb-0.2.0

- old
+ new

@@ -157,9 +157,11 @@ std::string s = String(value).str(); if (s == "mean") { return torch::Reduction::Mean; } else if (s == "sum") { return torch::Reduction::Sum; + } else if (s == "none") { + return torch::Reduction::None; } else { throw std::runtime_error("Unsupported reduction: " + s); } } };