"...gpu/git@developer.sourcefind.cn:gaoqiong/migraphx.git" did not exist on "9174b783e42056c84690da54beb9eab94cf7f163"
Commit 768a5eca authored by Khalique's avatar Khalique
Browse files

changed inheritance

parent 3e0b715a
......@@ -18,12 +18,19 @@ namespace migraphx {
inline namespace MIGRAPHX_INLINE_NS {
namespace op {
struct clip : unary
struct clip : unary<clip>
{
float max_val = std::numeric_limits<float>::max();
float min_val = std::numeric_limits<float>::min();
std::string name() const { return "clip"; }
auto apply() const
{
auto& max = max_val;
auto& min = min_val;
return [max, min](auto x) { return x > min ? (x < max ? x : max) : min; };
}
template <class Self, class F>
static auto reflect(Self& self, F f)
{
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment