From 20b1330cdbe4fa625a81bf4e2a18593722735dcd Mon Sep 17 00:00:00 2001 From: nihui Date: Wed, 18 Oct 2017 14:53:29 +0800 Subject: [PATCH] fix lrn within channel --- src/layer/arm/lrn_arm.cpp | 2 +- src/layer/lrn.cpp | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/layer/arm/lrn_arm.cpp b/src/layer/arm/lrn_arm.cpp index 4f5b471b3..868e862f0 100644 --- a/src/layer/arm/lrn_arm.cpp +++ b/src/layer/arm/lrn_arm.cpp @@ -84,7 +84,7 @@ int LRN_arm::forward_inplace(Mat& bottom_top_blob) const for (int q=0; q= channels) continue; diff --git a/src/layer/lrn.cpp b/src/layer/lrn.cpp index 5268f0ab6..1c40497ea 100644 --- a/src/layer/lrn.cpp +++ b/src/layer/lrn.cpp @@ -75,7 +75,7 @@ int LRN::forward(const Mat& bottom_blob, Mat& top_blob) const { // square sum float* outptr = top_blob.channel(q); - for (int p=q - local_size / 2; p= channels) continue; @@ -207,7 +207,7 @@ int LRN::forward_inplace(Mat& bottom_top_blob) const { // square sum float* ssptr = square_sum.channel(q); - for (int p=q - local_size / 2; p= channels) continue;