Skip to content
This repository has been archived by the owner on Nov 17, 2023. It is now read-only.

Commit

Permalink
Make more C++ unit tests work for batch norm (#28)
Browse files Browse the repository at this point in the history
* WIP unit tests

* some backward items initialized

* some backward items initialized

* some backward items initialized

* first unit test working

* Working on types

* backward types working for fp16 on first unit test

* backward types working for fp16 on first unit test

* backward types working for fp16 on first unit test

* .

* .

* some tests working

* fix input data

* hangle gpu<->cpu for setting values

* gpu working

* gpu working

* CAccessAsCPU class

* Fix varying type in AccessAsCPU

* starting to add channel axis tests

* TestChannelAxisSimple

* TestChannelAxisSimple

* run bidirectional

* run bidirectional

* run bidirectional

* CLEANUP

* CLEANUP

* ..

* noaxis

* ..

* lint

* revert

* revert
  • Loading branch information
cjolivier01 authored and zheng-da committed Feb 12, 2018
1 parent d637af1 commit be82804
Show file tree
Hide file tree
Showing 10 changed files with 876 additions and 833 deletions.
3 changes: 2 additions & 1 deletion src/operator/nn/batch_norm.cc
Original file line number Diff line number Diff line change
Expand Up @@ -382,7 +382,8 @@ static inline bool SupportMKLDNNBN(const NDArray &input, const BatchNormParam &p
TShape shape = input.shape();
return SupportMKLDNN(input) && shape.ndim() == 4
&& param.axis == mxnet::op::batchnorm::DEFAULT_AXIS
&& shape[param.axis] % 8 == 0;
&& shape[param.axis] % 8 == 0
&& !mxnet::op::batchnorm::disable_mkl;
}

void BatchNormComputeExCPU(const nnvm::NodeAttrs &attrs,
Expand Down
Loading

0 comments on commit be82804

Please sign in to comment.