Skip to content

Batch norm latest#5103

Merged
zchen0211 merged 7 commits intoPaddlePaddle:developfrom
zchen0211:batch-norm-latest
Oct 27, 2017
Merged

Batch norm latest#5103
zchen0211 merged 7 commits intoPaddlePaddle:developfrom
zchen0211:batch-norm-latest

Conversation

@zchen0211
Copy link
Contributor

Test with both NCHW and NHWC passed.

@zchen0211 zchen0211 requested a review from jacquesqiao October 25, 2017 23:27
x_val, scale_val, bias_val, epsilon, "NHWC")

#
mean_out = saved_mean * (1. - momentum) + momentum * mean
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

these three line can be moved to _reference_training

if core.is_compile_gpu() and core.op_support_gpu("batch_norm"):
places.append(core.GPUPlace(0))
for place in places:
test_with_place(place)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

可以加一层循环,把TensorFormat作为参数传给 test_with_place_and_dataformat

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

把四种case都测试到
CPU NCHW
CPU NWHC
GPU NCHW
GPU NWHC

Copy link
Member

@jacquesqiao jacquesqiao left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great Job!

@zchen0211 zchen0211 merged commit eaa4185 into PaddlePaddle:develop Oct 27, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

2 participants