| 1805 | } |
| 1806 | |
| 1807 | void softmax_all_gradient ( |
| 1808 | tensor& grad, |
| 1809 | const tensor& dest, |
| 1810 | const tensor& gradient_input |
| 1811 | ) |
| 1812 | { |
| 1813 | DLIB_CASSERT(have_same_dimensions(grad,dest)); |
| 1814 | DLIB_CASSERT(have_same_dimensions(grad,gradient_input)); |
| 1815 | ttimpl::softmax_gradient(1, grad.nr()*grad.nc()*grad.k(), grad, dest, gradient_input); |
| 1816 | } |
| 1817 | |
| 1818 | // ------------------------------------------------------------------------------------ |
| 1819 |