Add failure cases messages to BatchNorm test notebook

This commit is contained in:
AntreasAntoniou 2017-11-08 20:26:03 +00:00
parent b374414a0c
commit b42365c014

View File

@ -53,7 +53,12 @@
")\n", ")\n",
"\n", "\n",
"if shape_test and numerical_test:\n", "if shape_test and numerical_test:\n",
" print(\"Batch Normalization F-prop test passed\")" " print(\"Batch Normalization F-prop test passed\")\n",
"if numerical_test==False:\n",
" print(\"Batch Normalization F-prop numerical test failed\")\n",
"if shape_test==False:\n",
" print(\"Batch Normalization F-prop shape test failed\")\n",
" "
] ]
}, },
{ {
@ -82,7 +87,11 @@
")\n", ")\n",
"\n", "\n",
"if shape_test and numerical_test:\n", "if shape_test and numerical_test:\n",
" print(\"Batch Normalization B-prop test passed\")" " print(\"Batch Normalization B-prop test passed\")\n",
"if numerical_test==False:\n",
" print(\"Batch Normalization B-prop numerical test failed\")\n",
"if shape_test==False:\n",
" print(\"Batch Normalization B-prop shape test failed\")"
] ]
}, },
{ {
@ -120,7 +129,15 @@
")\n", ")\n",
"\n", "\n",
"if grads_gamma_shape_test and grads_gamma_numerical_test and grads_beta_shape_test and grads_beta_numerical_test:\n", "if grads_gamma_shape_test and grads_gamma_numerical_test and grads_beta_shape_test and grads_beta_numerical_test:\n",
" print(\"Batch Normalization grads wrt to params test passed\")" " print(\"Batch Normalization grads wrt to params test passed\")\n",
"if grads_gamma_numerical_test==False:\n",
" print(\"Batch Normalization grads_wrt_gamma numerical test failed\")\n",
"if grads_gamma_shape_test==False:\n",
" print(\"Batch Normalization grads_wrt_gamma shape test failed\")\n",
"if grads_beta_numerical_test==False:\n",
" print(\"Batch Normalization grads_wrt_beta numerical test failed\")\n",
"if grads_beta_shape_test==False:\n",
" print(\"Batch Normalization grads_wrt_beta shape test failed\")"
] ]
}, },
{ {
@ -151,5 +168,5 @@
} }
}, },
"nbformat": 4, "nbformat": 4,
"nbformat_minor": 2 "nbformat_minor": 1
} }