이춘석/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 8 Jun 2018 07:00:50 +0000 (16:00 +0900)]
Add sub/broadcast test into pureacl test (#1619)
Add sub/broadcast test into pureacl test
Signed-off-by: Chunseok Lee <chunseok.lee@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 8 Jun 2018 06:08:02 +0000 (15:08 +0900)]
Introduce from method in tensor::Shape (#1597)
This commit introduces from method in tensor::Shape which constructs
tensor::Shape object from a string.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 8 Jun 2018 05:43:31 +0000 (14:43 +0900)]
Introduce 'broadcast' method (#1610)
This commit introduces 'broadcast' method which computes the broadcasted
shape from two tensor shapes.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
이상규/동작제어Lab(SR)/Principal Engineer/삼성전자 [Fri, 8 Jun 2018 04:32:40 +0000 (13:32 +0900)]
Update submodule acl for sub broadcasting and reduce_max (#1616)
Added sub broadcasting and reduced max support.
Signed-off-by: Sanggyu Lee <sg5.lee@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 8 Jun 2018 03:29:45 +0000 (12:29 +0900)]
[Pure CL] Update TensorShape correctly (#1615)
This commit revises asTensorShape to update TensorShape correctly.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
서상민/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 8 Jun 2018 01:11:13 +0000 (10:11 +0900)]
Remove add_cast_ex_params (#1606)
For issue #1431
This patch removes `add_cast_ex_params` and its invocation from
nnapi_delegate.cpp because the type information of input and output is
already included in input and output operands; and the scalar values
added by `add_cast_ex_params` are not used anywhere.
Signed-off-by: Sangmin Seo <sangmin7.seo@samsung.com>
서상민/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 8 Jun 2018 01:03:26 +0000 (10:03 +0900)]
Add a workaround when scale for TENSOR_QUANT8_ASYMM is zero (#1605)
This patch adds a workaround, which changes `scale` to one when tensor's
scale is zero, because currently zero scale is passed down from TF Lite.
Note that the latest NeuralNetworks.h (see
https://android.googlesource.com/platform/frameworks/ml/+/master/nn/runtime/include/NeuralNetworks.h)
requires `scale` to be greater than zero. Remove this workaround when
the scale value is correctly passed.
Signed-off-by: Sangmin Seo <sangmin7.seo@samsung.com>
윤현식/동작제어Lab(SR)/Principal Engineer/삼성전자 [Fri, 8 Jun 2018 00:42:11 +0000 (09:42 +0900)]
pb file generator for TOPK (#1590)
`topk_3x3_n.py` contains Tensorflow code to generate pb/pbtxt of TOPK model.
Running topk_3x3_n.py will create four types of files:
1) pb/pbtxt after freezing (`graph_frozen.pb/pbtxt`)
2) pb/pbtxt before freezing (`graph.pb/pbtxt`)
3) Tensorboard files to visually see 1) and 2)
4) checkpoing files
Signed-off-by: Hyun Sik Yoon <hyunsik.yoon@samsung.com>
장지섭/동작제어Lab(SR)/Engineer/삼성전자 [Fri, 8 Jun 2018 00:32:26 +0000 (09:32 +0900)]
Support other type of operand for setting output of execution (#1580)
This commit support other type of operand for setting output of execution in pureacl.
- enable class VectorSink to use other type.
- enable calss FeatureSink to use other type.
- enable calss TensorSink to use other type
Signed-off-by: jiseob.jang <jiseob.jang@samsung.com>
이춘석/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 8 Jun 2018 00:23:57 +0000 (09:23 +0900)]
Add ok tests to pureacl test list (#1612)
gather, topkv2, div/broadcast, and concat2
Signed-off-by: Chunseok Lee <chunseok.lee@samsung.com>
서상민/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 8 Jun 2018 00:18:37 +0000 (09:18 +0900)]
[tflite_run] Generate uint8_t tensor input (#1604)
For issue #1431
This patch revises tflite_run's main function to also generate uint8_t
tensor input. It also adds assert(), which checks if the tensor type is
kTfLiteFloat32, to the else case where the float tensor input is
generated.
Signed-off-by: Sangmin Seo <sangmin7.seo@samsung.com>
서상민/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 8 Jun 2018 00:18:08 +0000 (09:18 +0900)]
Generate uint8_t tensor input in RandomTestRunner::run (#1603)
For issue #1431
This patch adds an initializer that generates uint8_t tensor input in
RandomTestRunner::run.
Signed-off-by: Sangmin Seo <sangmin7.seo@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Thu, 7 Jun 2018 11:21:20 +0000 (20:21 +0900)]
[Pure CL] Extract IExecutionBuilder (#1602)
This commit extracts IExecutionBuilder definition from compilation.cc
into a separate file.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
서상민/동작제어Lab(SR)/Staff Engineer/삼성전자 [Thu, 7 Jun 2018 09:56:12 +0000 (18:56 +0900)]
Add a unit test for CAST (#1608)
For issue #1431
This patch adds a unit test for CAST, which tests conversion from
unit8_t tensor to float tensor.
Signed-off-by: Sangmin Seo <sangmin7.seo@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Thu, 7 Jun 2018 09:39:20 +0000 (18:39 +0900)]
Add StrVar class (#1599)
This commit adds StrVar class which reads string value from environment
(as it is). Default value will be used if corresponding environment variable
does not exists.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
윤지영/동작제어Lab(SR)/Engineer/삼성전자 [Thu, 7 Jun 2018 09:38:51 +0000 (18:38 +0900)]
Add build requires (#1546)
Add build requires and add T/F Lite model description to help you understand
Signed-off-by: Jiyoung Yun <jy910.yun@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Thu, 7 Jun 2018 09:30:49 +0000 (18:30 +0900)]
Add 'TensorShapeUtils.h' (#1598)
This commit adds 'TensorShapeUtils.h' which includes as_dims function
which converts tensor::Shape as std::vector<int>.
This function is useful when construction NN model directly with tensorflow
lite interpreter.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Thu, 7 Jun 2018 09:26:07 +0000 (18:26 +0900)]
Introdduce tensor shape formatter (#1595)
This commit introduces default tensor shape formatter which makes it
easy to write output messages.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
박세희/동작제어Lab(SR)/Principal Engineer/삼성전자 [Thu, 7 Jun 2018 08:17:12 +0000 (17:17 +0900)]
Add JNI ACL test library (#1600)
This will create a JNI library that uses ACL graph library to test JNI-ACL is working from Android App
Signed-off-by: SaeHie Park <saehie.park@samsung.com>
박세희/동작제어Lab(SR)/Principal Engineer/삼성전자 [Thu, 7 Jun 2018 06:35:44 +0000 (15:35 +0900)]
Fix Werror option for ACL/Android (#1594)
This will fix giving two Werror option to ACL for Android
Signed-off-by: SaeHie Park <saehie.park@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Thu, 7 Jun 2018 06:23:50 +0000 (15:23 +0900)]
Introduce tensor::append method (#1588)
This commit introduces tensor::append method which allow users to extend
tensor shape.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
박세희/동작제어Lab(SR)/Principal Engineer/삼성전자 [Thu, 7 Jun 2018 04:33:22 +0000 (13:33 +0900)]
Fix indentation of build_android_rootfs script (#1587)
This will fix indentation of build_android_rootfs script from previous change
Signed-off-by: SaeHie Park <saehie.park@samsung.com>
박세희/동작제어Lab(SR)/Principal Engineer/삼성전자 [Thu, 7 Jun 2018 02:17:30 +0000 (11:17 +0900)]
Change of ACL build for Android (#1572)
* Change of ACL build for Android
This will change Makefile to build ACL for Android
ACL build output folders are separated by os-type to hold different os
Signed-off-by: SaeHie Park <saehie.park@samsung.com>
* use TARGET_OS
* more fix for android build
박세희/동작제어Lab(SR)/Principal Engineer/삼성전자 [Thu, 7 Jun 2018 02:11:28 +0000 (11:11 +0900)]
Update android roofs build script (#1576)
* Update android roofs build script
This will update android rootfs build script to option-ize inclusion of prebuilt ACL
and add gnustl toolchain folder for ACL build from source
Signed-off-by: SaeHie Park <saehie.park@samsung.com>
* remove additional dot
오형석/동작제어Lab(SR)/Staff Engineer/삼성전자 [Thu, 7 Jun 2018 02:01:44 +0000 (11:01 +0900)]
Support reduce max operation in Pure ACL runtime (#1579)
Support reduce max operation in Pure ACL runtime
Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Thu, 7 Jun 2018 01:53:22 +0000 (10:53 +0900)]
[Pure CL] Extract Sink class (#1585)
This commit extracts Sink class from execution.h and moves its
definition into newly introduced 'internal/Sink.h' header.
This commit also updates 'internal/Sinks.h' accordingly.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
오형석/동작제어Lab(SR)/Staff Engineer/삼성전자 [Thu, 7 Jun 2018 01:13:01 +0000 (10:13 +0900)]
Change custom max unittest (#1560)
Change custom max unittest
- Model input: remove axis
- Axis parameter: 1D tensor -> scalar
- Fix data order
Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Thu, 7 Jun 2018 01:12:34 +0000 (10:12 +0900)]
Introduce initializer map (#1573)
This commit introduces initializer map in RandomTestRunner to make it
easy to extend supported input types.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
오형석/동작제어Lab(SR)/Staff Engineer/삼성전자 [Thu, 7 Jun 2018 01:10:52 +0000 (10:10 +0900)]
More efficient format checker (#1571)
To reduce runtime by generating file list,
change current path using pushd/popd to subdirectories to check,
and generate file list
Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
오형석/동작제어Lab(SR)/Staff Engineer/삼성전자 [Tue, 5 Jun 2018 10:59:14 +0000 (19:59 +0900)]
Fix push-cross-build failure (#1578)
It is an error caused by timing.
A parameter of asTensorInfo() has been changed arm_compute::DataType to int32_t.
Signed-off-by: jiseob.jang <jiseob.jang@samsung.com>
최형규/동작제어Lab(SR)/Staff Engineer/삼성전자 [Tue, 5 Jun 2018 09:41:17 +0000 (18:41 +0900)]
Update STRIDED_SLICE in pureacl (#1539)
- Update external/acl
- Change type of parameters for STRIDED_SLICE of pureacl
, because type of parameters has been changed in ACL
Signed-off-by: Hyung-Kyu Choi <hk0110.choi@samsung.com>
장지섭/동작제어Lab(SR)/Engineer/삼성전자 [Tue, 5 Jun 2018 08:42:15 +0000 (17:42 +0900)]
Support other type of operand for setting input of execution (#1566)
This commit support other type of operand for setting input of execution in pure runtime.
- enable class VectorSource to use other type.
- enable calss FeatureSource to use other type.
Signed-off-by: jiseob.jang <jiseob.jang@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Tue, 5 Jun 2018 08:39:43 +0000 (17:39 +0900)]
Add 'static_nnfw_util' (#1568)
This commit adds 'static_nnfw_util' target which provides a static
nnfw_util library (to make it easy to deploy binaries).
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
이상규/동작제어Lab(SR)/Principal Engineer/삼성전자 [Tue, 5 Jun 2018 08:36:37 +0000 (17:36 +0900)]
Bring nn api test for sub.broadcast (#1563)
Related issue: #1338, #1379
NN API test for sub.broadcast is added. (Both of spec and generated c++ sources)
This code is based on Android NN `efd22b6`.
It is modified to test broadcasting of scalar value.
In addition, it fails. So I include it into skip lists.
Signed-off-by: Sanggyu Lee <sg5.lee@samsung.com>
장지섭/동작제어Lab(SR)/Engineer/삼성전자 [Tue, 5 Jun 2018 07:28:59 +0000 (16:28 +0900)]
Support Cast operation for pureACL (#1569)
This commit supports Cast operation for pureACL.
- support adding Cast operation via API related to model.
- The plan of Cast operation is not yet implemented.
Signed-off-by: jiseob.jang <jiseob.jang@samsung.com>
이상규/동작제어Lab(SR)/Principal Engineer/삼성전자 [Tue, 5 Jun 2018 06:11:24 +0000 (15:11 +0900)]
Support SUB_EX, DIV_EX in pure ACL (#1567)
SUB_EX and DIV_EX are supported in pure ACL.
We decided to put our extensions in extension,
even it is a part of NN API 1.1 and we already brought code.
Related issue: #1485
Signed-off-by: Sanggyu Lee <sg5.lee@samsung.com>
장지섭/동작제어Lab(SR)/Engineer/삼성전자 [Tue, 5 Jun 2018 06:04:42 +0000 (15:04 +0900)]
Support other type of operand in compilation of pure (#1552)
This commit supports other type of operand in compilation of pure.
- Change datatype of TensorInfo to get from model's operand.
- Add a function mapping type of OperandType to DataType of arm_compute.
Signed-off-by: jiseob.jang <jiseob.jang@samsung.com>
오형석/동작제어Lab(SR)/Staff Engineer/삼성전자 [Tue, 5 Jun 2018 05:49:45 +0000 (14:49 +0900)]
Pure CL: rename Max to ReduceMax (#1565)
Rename "Max" in pure cl runtime to "ReduceMax"
Tensorflow uses "reduce_max",
and extended operation "ANEURALNETWORKS_TENSORFLOW_MAX_EX" is translated from Tensorflow's "reduce_max" operation
Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
최성진/동작제어Lab(SR)/Principal Engineer/삼성전자 [Tue, 5 Jun 2018 02:52:22 +0000 (11:52 +0900)]
[Topkv2 Op] modify output's order of Topk_v2 operation (#1470)
This commit modifies output's order of Topk_v2 operation in runtime_run_android_nn_test.
-First one is values of output and second one is indexes of output.
Signed-off-by: SungJin Choi <lotieye.choi@samsung.com>
최성진/동작제어Lab(SR)/Principal Engineer/삼성전자 [Tue, 5 Jun 2018 01:53:17 +0000 (10:53 +0900)]
Enable gather operation test for test_driver (#1556)
This commit enables gather operation test for test_driver.
Signed-off-by: SungJin Choi <lotieye.choi@samsung.com>
오형석/동작제어Lab(SR)/Staff Engineer/삼성전자 [Tue, 5 Jun 2018 01:25:33 +0000 (10:25 +0900)]
Remove unused files to support custom operator (#1557)
Remove unused files in tools/tflite_run to support custom operator
Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
최성진/동작제어Lab(SR)/Principal Engineer/삼성전자 [Tue, 5 Jun 2018 00:57:39 +0000 (09:57 +0900)]
Add int32 initialization to tflite_run (#1550)
This commit adds int32 initialization to tflite_run.
-With gather operation, index should be within input coverage.
Signed-off-by: SungJin Choi <lotieye.choi@samsung.com>
최성진/동작제어Lab(SR)/Principal Engineer/삼성전자 [Tue, 5 Jun 2018 00:26:53 +0000 (09:26 +0900)]
[Gather Op-PureACL] add gather operation to pure acl runtime (#1541)
This commits adds gather operation to pure acl runtime.
Signed-off-by: SungJin Choi <lotieye.choi@samsung.com>
장지섭/동작제어Lab(SR)/Engineer/삼성전자 [Mon, 4 Jun 2018 23:22:54 +0000 (08:22 +0900)]
Remove assertion to check data type (#1553)
This commit removes assertion to checkout datatype because it is no longer needed.
Signed-off-by: jiseob.jang <jiseob.jang@samsung.com>
장지섭/동작제어Lab(SR)/Engineer/삼성전자 [Mon, 4 Jun 2018 23:22:03 +0000 (08:22 +0900)]
Add type info of operands to Model in pure (#1551)
This commit adds type info of operands to Model in pure.
Signed-off-by: jiseob.jang <jiseob.jang@samsung.com>
서상민/동작제어Lab(SR)/Staff Engineer/삼성전자 [Mon, 4 Jun 2018 23:19:05 +0000 (08:19 +0900)]
Add a TopK_V2 unit test (#1548)
For issue #1367
This patch adds a unit test for TOPK_V2.
Signed-off-by: Sangmin Seo <sangmin7.seo@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Mon, 4 Jun 2018 23:18:32 +0000 (08:18 +0900)]
nnfw_support_tflite as static (#1544)
This commit marks nnfw_support_tflite explicitly as static library
target to make it easy to use this library for android applications.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
서상민/동작제어Lab(SR)/Staff Engineer/삼성전자 [Mon, 4 Jun 2018 09:31:53 +0000 (18:31 +0900)]
[PureCL] Support TopK_V2 for vector input (#1545)
For issue #1367
This patch fills the ACL configuration part in the Pure CL runtime for
TopK_V2 operation. It also revises the order of parameters in the
TopKV2 implementation, so the parameter order matches the argument order
of ACL's configure routine.
Signed-off-by: Sangmin Seo <sangmin7.seo@samsung.com>
이춘석/동작제어Lab(SR)/Staff Engineer/삼성전자 [Mon, 4 Jun 2018 08:42:53 +0000 (17:42 +0900)]
Run framework/verification test from file list (#1537)
* Run framework/verification test from file list
1. Add --frameworktest_list_file option to test_driver.sh
2. Add pureacl_frameworktest_list.txt which contains models for pureacl runtime
test.
Signed-off-by: Chunseok Lee <chunseok.lee@samsung.com>
오형석/동작제어Lab(SR)/Staff Engineer/삼성전자 [Mon, 4 Jun 2018 08:37:08 +0000 (17:37 +0900)]
Set parameter for reduce max in pure cl (#1542)
Set parameter for reduce max in pure cl compilation step
It can handle special case only: maxtrix input, vector output, one constant axis
Comment out calling arm cl API call: not implemented yet
Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
이상규/동작제어Lab(SR)/Principal Engineer/삼성전자 [Mon, 4 Jun 2018 08:28:35 +0000 (17:28 +0900)]
Implement Sub in PureACL runtime (#1540)
Related issue: #1338, #1379
Support sub in pure acl.
It is implementation in pure acl runtime.
nnapi_unittests Sub for same shape works.
But for broadcasting, I need further work in ACL kernel.
Signed-off-by: Sanggyu Lee <sg5.lee@samsung.com>
오형석/동작제어Lab(SR)/Staff Engineer/삼성전자 [Mon, 4 Jun 2018 08:08:21 +0000 (17:08 +0900)]
Use custom operator kernel in support (#1536)
tflite_run and nnapi_test use upport/tflite/kernel/CustomOps.h
to support custom operator in tflite interpreter
Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
이상규/동작제어Lab(SR)/Principal Engineer/삼성전자 [Mon, 4 Jun 2018 07:40:37 +0000 (16:40 +0900)]
Add nnapi_unittests for Sub (#1534)
Related issue: #1379, #1338
To verify Sub on pure ACL runtime, Sub nnapi_unittests are added.
sub_1 is for same shape input. sub_2 for broadcasting.
Signed-off-by: Sanggyu Lee <sg5.lee@samsung.com>
서상민/동작제어Lab(SR)/Staff Engineer/삼성전자 [Mon, 4 Jun 2018 06:38:58 +0000 (15:38 +0900)]
Update the ACL submodule to the latest. (#1532)
This patch updates the hash of ACL submodule to the latest.
Signed-off-by: Sangmin Seo <sangmin7.seo@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Mon, 4 Jun 2018 06:36:02 +0000 (15:36 +0900)]
[android build] Fix typo and error in CMake (#1533)
This commit fixes typo and errors in Tensorflow Lite build support.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
오형석/동작제어Lab(SR)/Staff Engineer/삼성전자 [Mon, 4 Jun 2018 06:00:56 +0000 (15:00 +0900)]
Add ndk default path in gitignore list (#1538)
Ignore ndk default path generated by build_android_rootfs.sh
Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
장지섭/동작제어Lab(SR)/Engineer/삼성전자 [Mon, 4 Jun 2018 05:30:57 +0000 (14:30 +0900)]
Move `include <cassert>` from support.h to support.cpp (#1531)
This commit moves `include <cassert>` from support.h to support.cpp.
Signed-off-by: jiseob.jang <jiseob.jang@samsung.com>
오형석/동작제어Lab(SR)/Staff Engineer/삼성전자 [Mon, 4 Jun 2018 04:20:56 +0000 (13:20 +0900)]
Pure CL: Tensorinfo for other type (#1530)
Now TensorInfo can use F32 type only
Define more asTensorInfo to use other type
Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
최형규/동작제어Lab(SR)/Staff Engineer/삼성전자 [Mon, 4 Jun 2018 03:37:12 +0000 (12:37 +0900)]
Implement STRIDED_SLICE in PureACL (#1523)
* Implement STRIDED_SLICE in PureACL
- Introduce ANEURALNETWORKS_STRIDED_SLICE_EX to addOperationEx
- Implement visitor of STRIDED_SLICE in PureACL with incomplete parameter
- Fix bug in assert condition
- Fix typo in variable name
Signed-off-by: Hyung-Kyu Choi <hk0110.choi@samsung.com>
* Fix format
- Fix format
Signed-off-by: Hyung-Kyu Choi <hk0110.choi@samsung.com>
장지섭/동작제어Lab(SR)/Engineer/삼성전자 [Mon, 4 Jun 2018 03:32:48 +0000 (12:32 +0900)]
Enable other types to use class Reader (#1516)
This commit other types to use class Reader.
Signed-off-by: jiseob.jang <jiseob.jang@samsung.com>
장지섭/동작제어Lab(SR)/Engineer/삼성전자 [Mon, 4 Jun 2018 02:47:33 +0000 (11:47 +0900)]
Enable other types for class View (#1520)
This commit enables other types for class View.
Signed-off-by: jiseob.jang <jiseob.jang@samsung.com>
서상민/동작제어Lab(SR)/Staff Engineer/삼성전자 [Mon, 4 Jun 2018 02:45:54 +0000 (11:45 +0900)]
Enable TopK_V2 framework test (#1529)
This patch enables the TopK_V2 framework test, as the NN runtime with
CPU fallback now can correctly execute it.
Signed-off-by: Sangmin Seo <sangmin7.seo@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Mon, 4 Jun 2018 01:59:06 +0000 (10:59 +0900)]
Selective format check (#1519)
This commit allows users to disable CPP/Python format check via
CHECK_CPP/CHECK_PYTHON environment variables.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Mon, 4 Jun 2018 01:58:30 +0000 (10:58 +0900)]
Introduce 'IndexEnumerator' (#1502)
This commit introduces 'tensor::IndexEnumerator' and uses it to simplify
the implementation of 'tensor::IndexIterator'.
Unlike 'tensor::IndexIterator', 'tensor::IndexEnumerator' can be used in for loop
similarly as C++ standard iterator.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Mon, 4 Jun 2018 01:51:01 +0000 (10:51 +0900)]
[Pure CL] Add setPreference and free (#1524)
* [Pure CL] Add setPreference and free
This commit implements ANeuralNetworksCompilation_setPreference and
ANeuralNetworksCompilation_free in pure CL runtime.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
* Fix format errors
서상민/동작제어Lab(SR)/Staff Engineer/삼성전자 [Mon, 4 Jun 2018 01:06:25 +0000 (10:06 +0900)]
[PureCL] Accept TopK_V2 (#1528)
For issue #1367
This patch adds boilerplate code to accept TopK_V2 operation in the Pure
CL runtime. After this commit, a remaining piece to support TopK_V2 in
the Pure CL runtime will be the configuration step for ACL.
Signed-off-by: Sangmin Seo <sangmin7.seo@samsung.com>
이춘석/동작제어Lab(SR)/Staff Engineer/삼성전자 [Mon, 4 Jun 2018 00:50:46 +0000 (09:50 +0900)]
BUILD_PURE_ARM_COMPUTE=ON for armv7l non-tizen (#1521)
To check pureacl runtime's build break, make BUILD_PURE_ARM_COMPUTE=ON for
armv7l non-tizen.
Signed-off-by: Chunseok Lee <chunseok.lee@samsung.com>
박세희/동작제어Lab(SR)/Principal Engineer/삼성전자 [Mon, 4 Jun 2018 00:40:40 +0000 (09:40 +0900)]
Add compilation option for android arm64 (#1490)
This will add compilation option for android arm64 build
Signed-off-by: SaeHie Park <saehie.park@samsung.com>
최성진/동작제어Lab(SR)/Principal Engineer/삼성전자 [Mon, 4 Jun 2018 00:14:45 +0000 (09:14 +0900)]
[ACL Patch] update gather operation for ACL OpenCL (#1492)
This commit introduce gather operation for ACL OpenCL as an early stage.
-naive version
-only tested for 2D input and 1D indexes
-TODO: performance tuning
Signed-off-by: lotieye.choi <lotieye.choi@samsung.com>
오형석/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 1 Jun 2018 10:57:31 +0000 (19:57 +0900)]
Implement custom op kernel in support/tflite (#1478)
* Implement custom op kernel in support/tflite
Implement custom op kernel in support/tflite
Copy from tflite_run and define nameapce
Namespace: nnfw::ops::custom::nnfw::<opname>
Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
* Add ifdef in TensorFlowMax.h
Add ifdef in TensorFlowMax.h
Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
* Change filename tensorflowmax.cpp
Change filename tensorflowmax.cpp => TensorFlowMax.cpp
Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
장지섭/동작제어Lab(SR)/Engineer/삼성전자 [Fri, 1 Jun 2018 10:34:37 +0000 (19:34 +0900)]
Fix invalid typename in template class (#1517)
This commit fixes invalid typename in template class.
Signed-off-by: jiseob.jang <jiseob.jang@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 1 Jun 2018 08:28:09 +0000 (17:28 +0900)]
[nnapi_test] Support Int32 output compare (#1518)
* [nnapi_test] Support Int32 output compare
This commit revises nnapi_test to support int32 output compare.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
* Fix format errors
최형규/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 1 Jun 2018 08:11:19 +0000 (17:11 +0900)]
Introduce dummy STRIDED_SLICE kernel to pure_arm_compute (#1497)
- Introduce dummy STRIDED_SLICE kernel to pure_arm_compute
Signed-off-by: Hyung-Kyu Choi <hk0110.choi@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 1 Jun 2018 08:10:48 +0000 (17:10 +0900)]
Implement ANeuralNetworksModel_addOperationEx in sample runtimes (#1515)
This commit implements ANeuralNetworksModel_addOperationEx in sample
runtimes (logging, template).
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 1 Jun 2018 07:52:59 +0000 (16:52 +0900)]
Add Diff constructor (#1512)
This commit adds a constructor to 'nnfw::util::tensor::Diff' which
initializes expected/obtained fields, and simplifies Comparator
implementation using this new constructor.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
이춘석/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 1 Jun 2018 07:47:30 +0000 (16:47 +0900)]
make acl on pureacl arm cross build script (#1514)
BUILD_ACL does not support embeded kernel. To avoid cl_kernels installation on
test job, this commit disables BUILD_ACL and do `make acl` on arm cross build script.
Signed-off-by: Chunseok Lee <chunseok.lee@samsung.com>
오형석/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 1 Jun 2018 07:23:57 +0000 (16:23 +0900)]
Add custom tensorflowmax unittest (#1501)
Add unittest for custom tensorflowmax
2D (float, int32) input => 1D output
Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
이상규/동작제어Lab(SR)/Principal Engineer/삼성전자 [Fri, 1 Jun 2018 06:32:52 +0000 (15:32 +0900)]
Fix build error std::function on pure acl runtime (#1505)
I include <functional> explicitly for std::function.
Related Issue: #1503
Signed-off-by: Sanggyu Lee <sg5.lee@samsung.com>
이춘석/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 1 Jun 2018 06:31:28 +0000 (15:31 +0900)]
Remove ARMCL_DIR setting from arm-ubunut pureacl build script (#1504)
This commit removes ARMCL_DIR from docker_build_cross_arm_pureacl.sh
Signed-off-by: Chunseok Lee <chunseok.lee@samsung.com>
오형석/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 1 Jun 2018 06:29:18 +0000 (15:29 +0900)]
Define Max namespace in pure acl runtime (#1506)
Define Max namespace, node, param in pure acl runtime
Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 1 Jun 2018 06:14:34 +0000 (15:14 +0900)]
[nnapi_test] Support int32 input generation (#1498)
With this commit, nnapi_test is able to generate int32 input tensors.
Note that random generation is not supported, yet.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 1 Jun 2018 06:13:39 +0000 (15:13 +0900)]
Show used NN runtime filepath (#1496)
This commit shows the filepath of NN runtime being used.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
오형석/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 1 Jun 2018 06:05:46 +0000 (15:05 +0900)]
Set addOperationEx return value in pure acl runtime (#1507)
Set addOperationEx return value in pure acl runtime
To avoid conflict, commit small change.
Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 1 Jun 2018 05:51:04 +0000 (14:51 +0900)]
[NNAPI unittest] Add 'add_2' case (#1464)
* [NNAPI unittest] Add 'add_2' case
This commit adds 'add_2' unittest which takes RHS as an input, but LHS
is a constant.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
* Fix format errors
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 1 Jun 2018 05:48:28 +0000 (14:48 +0900)]
Type-based tensor output compare (#1499)
This commit introduces type-based tensor output compare infrastructure
in TfLiteInterpMatchApp.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
최성진/동작제어Lab(SR)/Principal Engineer/삼성전자 [Fri, 1 Jun 2018 04:06:13 +0000 (13:06 +0900)]
[Gather OP] add nnapi delegate for Gather operation (#1465)
This commit adds nnapi delegate for Gather operation.
-axis parameter is added
Signed-off-by: SungJin Choi <lotieye.choi@samsung.com>
이춘석/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 1 Jun 2018 03:27:11 +0000 (12:27 +0900)]
Add script to build pure_arm_compute runtime (#1484)
* Add script to build pure_arm_compute runtime
1. Add script to cross-build pure_arm_compute runtime for both arm-ubunut and tizen
To run test, please set LD_LIBRARY_PATH=Product/lib/pureacl instead of
Product/lib.
Signed-off-by: Chunseok Lee <chunseok.lee@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 1 Jun 2018 03:17:53 +0000 (12:17 +0900)]
Flexible input generation switch for RandomTestRunner (#1495)
This commit revises RandomTestRunner to make it easy to extend supported
input type.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
오형석/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 1 Jun 2018 02:56:01 +0000 (11:56 +0900)]
More tests for STRIDED_SLICE_EX (#1488)
Add more test for STRIDE_SLICE_EX
It's similar with STRIDE_SLICE (Fix argument)
Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 1 Jun 2018 02:35:13 +0000 (11:35 +0900)]
[support.tflite] Generic TensorView (#1494)
This commit revises TensorView class as a generic class.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 1 Jun 2018 02:02:57 +0000 (11:02 +0900)]
Detect NNAPI load failure (#1489)
This commit revises NeuralNetworksShim.h and NeuralNetworksExShim.h to
abort execution when NNAPI functions are unavailable, but used.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
최성진/동작제어Lab(SR)/Principal Engineer/삼성전자 [Fri, 1 Jun 2018 01:18:30 +0000 (10:18 +0900)]
[Topkv2 OP] add nnapi delegate for Topk_v2 operation (#1463)
* [Topkv2 OP] add nnapi delegate for Topk_v2 operation
This commit add nnapi delegate for Topk_v2 operation.
-change output order (output_value is first and output_index is second)
Signed-off-by: SungJin Choi <lotieye.choi@samsung.com>
* [Topkv2 OP] add nnapi delegate for Topk_v2 operation
This commit add nnapi delegate for Topk_v2 operation.
-change output order (output_value is first and output_index is second)
Signed-off-by: SungJin Choi <lotieye.choi@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 1 Jun 2018 01:05:30 +0000 (10:05 +0900)]
[tflite_benchmark] Show benchmark configurations (#1491)
This commit revises tflite_benchmark to show benchmark configurations
before running benchmark.
Currently, the following configurations will be shown:
- The number of threads to be used
- Whether NNAPI is used, or not
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
서상민/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 1 Jun 2018 00:38:50 +0000 (09:38 +0900)]
[PureCL] Support DIV operation (#1482)
* [PureCL] Support DIV operation
For #1338 and #1366
This patch adds DIV operation to the pure ACL runtime.
Signed-off-by: Sangmin Seo <sangmin7.seo@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Fri, 1 Jun 2018 00:18:18 +0000 (09:18 +0900)]
Update Android build scripts (#1487)
This commit revises 'build_android_rootfs.sh' to create ndk directory
for tensorflow lite buiild, and updates tensorflow lite CMakeLists.txt
to access this NDK during build.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
이한종/동작제어Lab(SR)/Engineer/삼성전자 [Thu, 31 May 2018 11:49:14 +0000 (20:49 +0900)]
[tflite_run] Generate random input (#1477)
When running `tflite_run` without input argument it runs with values
with 0. This commit will fill the input tensors with random values
instead, same way with `nnapi_test` does.
Signed-off-by: Hanjoung Lee <hanjoung.lee@samsung.com>
이춘석/동작제어Lab(SR)/Staff Engineer/삼성전자 [Thu, 31 May 2018 11:48:27 +0000 (20:48 +0900)]
Submodule update on internal_acl_build (#1483)
`make acl` does not work on fresh repo. This commit makes submodule update on
target internal_acl_build.
Signed-off-by: Chunseok Lee <chunseok.lee@samsung.com>
최성진/동작제어Lab(SR)/Principal Engineer/삼성전자 [Thu, 31 May 2018 11:46:10 +0000 (20:46 +0900)]
[Gather Op] add axis to runtime_run_android_nn_test (#1479)
This commit adds axis to runtime_run_android_nn_test.
-axis parameter is added newly.
Signed-off-by: SungJin Choi <lotieye.choi@samsung.com>
박종현/동작제어Lab(SR)/Staff Engineer/삼성전자 [Thu, 31 May 2018 08:43:27 +0000 (17:43 +0900)]
[Pure CL] Introduce Const Tensor View (#1474)
This commit introduces ConstView class to make it easy to write generic
const operand updates.
Signed-off-by: Jonghyun Park <jh1302.park@samsung.com>
최형규/동작제어Lab(SR)/Staff Engineer/삼성전자 [Thu, 31 May 2018 07:56:29 +0000 (16:56 +0900)]
Update comment for STRIDED_SLICE in NeuralNetworks.h (#1460)
- Update comment for STRIDED_SLICE in NeuralNetworks.h,
because operands of STRIDED_SLICE has been implemented by
following parameters defined in the latest Android NN API.
Signed-off-by: Hyung-Kyu Choi <hk0110.choi@samsung.com>