[tensor] Optimize element wise operator functions
authorParichay Kapoor <pk.kapoor@samsung.com>
Thu, 28 Oct 2021 08:03:02 +0000 (17:03 +0900)
committerJijoong Moon <jijoong.moon@samsung.com>
Fri, 29 Oct 2021 05:39:49 +0000 (14:39 +0900)
commit52a2c78b11dba315a4bd05860bf8af767bd71631
treee567954963b2470d38bbe90edb582ef1785f8f8d
parent3eb8db66c562ea149e715027697375014ace8ca5
[tensor] Optimize element wise operator functions

This patch optimizes element-wise operator functions for multiply,
divide, add and subtract by using std::transform than regular loop when
the stride along the last dimension is 1.

Signed-off-by: Parichay Kapoor <pk.kapoor@samsung.com>
nntrainer/tensor/tensor.cpp