From 91432cb503953bb08ecea3ff063b206afb804001 Mon Sep 17 00:00:00 2001 From: guo ran <360112263@qq.com> Date: Thu, 6 Sep 2018 11:23:41 +0800 Subject: [PATCH] fix Div function (#1212) --- oneflow/core/kernel/softmax_kernel.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/oneflow/core/kernel/softmax_kernel.cpp b/oneflow/core/kernel/softmax_kernel.cpp index e242fcc87f..896a7d5ccf 100644 --- a/oneflow/core/kernel/softmax_kernel.cpp +++ b/oneflow/core/kernel/softmax_kernel.cpp @@ -90,7 +90,7 @@ struct SoftmaxKernelUtil { static void Div(DeviceCtx* ctx, const int64_t n, const int64_t w, T* matrix, const T* vector) { for (int64_t i = 0; i < n; ++i) { - KernelUtil::Div(ctx, n, matrix + i * w, vector + i); + KernelUtil::Div(ctx, w, matrix + i * w, vector + i); } } }; -- GitLab