From d9e706a10824e40d56b9e94a3879da970907e930 Mon Sep 17 00:00:00 2001 From: Da Zheng Date: Mon, 27 Nov 2017 22:22:29 +0000 Subject: [PATCH] Fix a compilation error in activation. --- src/operator/nn/activation-inl.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/src/operator/nn/activation-inl.h b/src/operator/nn/activation-inl.h index c46c33d6dfda..5e701a205e1e 100644 --- a/src/operator/nn/activation-inl.h +++ b/src/operator/nn/activation-inl.h @@ -68,9 +68,9 @@ void ActivationForward(const OpContext &ctx, const TBlob &in_data, using namespace mshadow; using namespace mshadow::expr; Stream *s = ctx.get_stream(); - const size_t sz = input.shape_.Size(); + const size_t sz = in_data.shape_.Size(); if (sz) { - MXNET_ASSIGN_REQ_SWITCH(req[activation::kOut], Req, { + MXNET_ASSIGN_REQ_SWITCH(req, Req, { mxnet_op::Kernel, xpu>::Launch( s, sz, out_data.dptr(), @@ -88,7 +88,7 @@ void ActivationBackward(const OpContext &ctx, const TBlob &out_grad, Stream *s = ctx.get_stream(); const size_t sz = out_data.shape_.Size(); if (sz) { - MXNET_ASSIGN_REQ_SWITCH(req[activation::kData], Req, { + MXNET_ASSIGN_REQ_SWITCH(req, Req, { mxnet_op::Kernel, Req>, xpu>::Launch( s, sz,