platform/core/ml/nnfw.git
5 years ago[neurun] Schedule ops in holes/gaps of a backends (#5557)
Дилшоджон Умронхонович Пошшоев/AI Tools Lab /SRR/Engineer/삼성전자 [Tue, 16 Jul 2019 10:23:04 +0000 (19:23 +0900)]
[neurun] Schedule ops in holes/gaps of a backends (#5557)

So far scheduler assumed a backend is occupied totally and there is no
gaps/holes between two tasks. This change adds this support.
Also, this change adds the concideration of occupation of cpu bywq! permutation

Signed-off-by: Poshshoev Dilshodzhon <d.poshshoev@samsung.com>
5 years ago[neurun] Fix linear interpolation in ExecTime::getOperationExecTime (#5614)
Дилшоджон Умронхонович Пошшоев/AI Tools Lab /SRR/Engineer/삼성전자 [Tue, 16 Jul 2019 10:13:44 +0000 (19:13 +0900)]
[neurun] Fix linear interpolation in ExecTime::getOperationExecTime (#5614)

In some cases ops with smaller inputs is executed slower than the one
with larger inputs, more likely because of a backend's load difference.
In such cases result of lin-interpolation is negative, which is wrong

Signed-off-by: Dilshodzhon Poshshoev <d.poshshoev@samsung.com>
5 years agoMove cmake directory (#5648)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Tue, 16 Jul 2019 09:21:47 +0000 (18:21 +0900)]
Move cmake directory (#5648)

* Move cmake directory

Move cmake script directory to infra/nnfw/cmake
Move root CMakeLists.txt to infra/nnfw

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
* Define NNFW_SOURCE_ROOT and use

5 years agoEnable acl layout test again (#5650)
장지섭/On-Device Lab(SR)/Engineer/삼성전자 [Tue, 16 Jul 2019 08:10:06 +0000 (17:10 +0900)]
Enable acl layout test again (#5650)

* Enable acl layout test again

This commit enables acl layout test again.

Signed-off-by: jiseob.jang <jiseob.jang@samsung.com>
* Apply layout for padding data of PadLayer

This commit applies layout for padding data of PadLayer.

Signed-off-by: jiseob.jang <jiseob.jang@samsung.com>
5 years agoUpdate install-githooks command (#5647)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Tue, 16 Jul 2019 08:09:53 +0000 (17:09 +0900)]
Update install-githooks command (#5647)

- Use NNFW_PROJECT_PATH instead of relative path
- Check pre-push hook existance and update with backup or remove

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
5 years agoFix pylint warning in tf model freezer (#5632)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Tue, 16 Jul 2019 05:17:04 +0000 (14:17 +0900)]
Fix pylint warning in tf model freezer (#5632)

Fix pylint warning by
- Pointless string (for comment): change to comment
- Bad super parameter: change old style self.__class__ to classname itself

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
5 years ago[neurun] Sequance replaced with FunctionSequance in linear executor (#5653)
Ivan Vagin/AI Tools Lab /SRR/Engineer/삼성전자 [Tue, 16 Jul 2019 03:39:02 +0000 (06:39 +0300)]
[neurun] Sequance replaced with FunctionSequance in linear executor (#5653)

* [neurun] Sequance replaced with FunctionSequance

* Sequance replaced with FunctionSequance in linear executor

Signed-off-by: Ivan Vagin <ivan.vagin@samsung.com>
* Fixed formatting

Signed-off-by: Ivan Vagin <ivan.vagin@samsung.com>
5 years agoFix set output shape incorrectly of PermuteLayer (#5649)
장지섭/On-Device Lab(SR)/Engineer/삼성전자 [Tue, 16 Jul 2019 03:27:26 +0000 (12:27 +0900)]
Fix set output shape incorrectly of PermuteLayer (#5649)

This commit fixes set output shape incorrectly of PermuteLayer.

Signed-off-by: jiseob.jang <jiseob.jang@samsung.com>
5 years ago[neurun] Made ShapeInference to consume shapes instead of nodes (#5652)
Ivan Vagin/AI Tools Lab /SRR/Engineer/삼성전자 [Tue, 16 Jul 2019 01:04:55 +0000 (04:04 +0300)]
[neurun] Made ShapeInference to consume shapes instead of nodes (#5652)

Made ShapeInference to consume shapes instead of nodes

Signed-off-by: Ivan Vagin <ivan.vagin@samsung.com>
5 years agoMove git push hook install script (#5643)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Mon, 15 Jul 2019 10:46:22 +0000 (19:46 +0900)]
Move git push hook install script (#5643)

- Make git hook install to command
- Move hook script to infra/nnfw/git-hooks
- Change hook script name: .sh file extension
- Update format checker: remove exceptional check policy for hook script

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
5 years agoRemove ConfigManager that is no longer used (#5641)
이한종/On-Device Lab(SR)/Engineer/삼성전자 [Mon, 15 Jul 2019 10:35:40 +0000 (19:35 +0900)]
Remove ConfigManager that is no longer used (#5641)

Now `ConfigSource` is used instead.

Signed-off-by: Hanjoung Lee <hanjoung.lee@samsung.com>
5 years agoUpgrade to tensorflow v1.13.1 (#5590)
이춘석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Mon, 15 Jul 2019 10:24:34 +0000 (19:24 +0900)]
Upgrade to tensorflow v1.13.1 (#5590)

* Upgrade to tensorflow v1.13.1

- update link to v1.13.1
- tensorflow/contribe/lite to tensorflow/lite
- TFLITE_MINOR_VER to 13

Signed-off-by: Chunseok Lee <chunseok.lee@samsung.com>
* upgrade absl to 389ec3f90

* add custom for SquaredDifference

* Fix x64 build error(Eigen)

- update eigen version to 88fc23324517

* fix wrong comment : lite -> contrib/lite

5 years agoRefactor IDotInfo and its derivatives (#5581)
이한종/On-Device Lab(SR)/Engineer/삼성전자 [Mon, 15 Jul 2019 10:16:49 +0000 (19:16 +0900)]
Refactor IDotInfo and its derivatives (#5581)

This commit refactors `IDotInfo` and its derivatives - `DotOperandInfo`
and `DotNodeInfo`.

- `IDotInfo` -> `Node` (represents "Node" of DOT format)
- `DotOperandInfo` -> `OperandNode`
- `DotNodeInfo` -> `OperationNode`
- `NodeAttr` -> removed

Now `Node` manages a map of attributes which behaves almost same with
`NodeAttr` so it has been removed.

Signed-off-by: Hanjoung Lee <hanjoung.lee@samsung.com>
5 years agoFix gbs build script and configure file (#5640)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Mon, 15 Jul 2019 09:01:40 +0000 (18:01 +0900)]
Fix gbs build script and configure file (#5640)

Fix configure file path
Remove useless password (obs_viewer - readonly don't need password)

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
5 years ago[model parser] Update to support model using tensorflow 1.13.1 (#5625)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Mon, 15 Jul 2019 08:59:50 +0000 (17:59 +0900)]
[model parser] Update to support model using tensorflow 1.13.1 (#5625)

Update generated API files from schma.fbs in tensorflow 1.13.1

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
5 years ago[neurun] Change acl_cl::Object::access to multithread safe (#5636)
Дилшоджон Умронхонович Пошшоев/AI Tools Lab /SRR/Engineer/삼성전자 [Mon, 15 Jul 2019 08:59:22 +0000 (17:59 +0900)]
[neurun] Change acl_cl::Object::access to multithread safe (#5636)

Calling access for more than one tensor causing an error in map()

Signed-off-by: Dilshodzhon Poshshoev <d.poshshoev@samsung.com>
5 years agoMake dedicated class for neurun's tensor shape (#5621)
Сергей Баранников/AI Tools Lab /SRR/Engineer/삼성전자 [Mon, 15 Jul 2019 08:52:26 +0000 (11:52 +0300)]
Make dedicated class for neurun's tensor shape (#5621)

Related issue: #5472

Remove dependency of model::Shape on misc::tensor::Shape.

Signed-off-by: Sergei Barannikov <s.barannikov@samsung.com>
5 years ago[kbenchmark] rename acl kernel directory (#5570)
윤지영/On-Device Lab(SR)/Staff Engineer/삼성전자 [Mon, 15 Jul 2019 08:37:58 +0000 (17:37 +0900)]
[kbenchmark] rename acl kernel directory (#5570)

* [kbenchmark] rename acl kernel directory

armcl to acl_cl
armne to acl_neon

Signed-off-by: Jiyoung Yun <jy910.yun@samsung.com>
* Change the include directory path

* Do not print psABI warnings

5 years agoRelocate nnfw configurations (#5638)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Mon, 15 Jul 2019 08:20:21 +0000 (17:20 +0900)]
Relocate nnfw configurations (#5638)

- Introduce and use import function to remove dependency with NNFW_SCRIPT_PATH in commands
- Move script/config to infra/nncc/config directory

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
5 years ago[neurun] Use Object instead of ICLTensor in acl_cl::concat (#5637)
Дилшоджон Умронхонович Пошшоев/AI Tools Lab /SRR/Engineer/삼성전자 [Mon, 15 Jul 2019 08:19:22 +0000 (17:19 +0900)]
[neurun] Use Object instead of ICLTensor in acl_cl::concat (#5637)

This change is done to replace explicitely calling acl::map/unmap
with Object::access, so that we can controll it in one place.
This change is needed for PR 5636

Signed-off-by: Dilshodzhon Poshshoev <d.poshshoev@samsung.com>
5 years ago[neurun] Switch to KernelGenerator and remove StageGenerator (#5615)
Сергей Баранников/AI Tools Lab /SRR/Engineer/삼성전자 [Mon, 15 Jul 2019 07:58:01 +0000 (10:58 +0300)]
[neurun] Switch to KernelGenerator and remove StageGenerator (#5615)

Related issue: #5460
Related draft: #5481

Switch to KernelGenerator and remove StageGenerator.

Signed-off-by: Sergei Barannikov <s.barannikov@samsung.com>
5 years ago[neurun] Implemented shape inference for AvgPool2DNode (#5624)
Ivan Vagin/AI Tools Lab /SRR/Engineer/삼성전자 [Mon, 15 Jul 2019 07:04:54 +0000 (10:04 +0300)]
[neurun] Implemented shape inference for AvgPool2DNode (#5624)

* Implemented shape inference for AvgPool2DNode
* Implemented unittests for AvgPool2DNode shape inference
* Minor fixes in ShapeInference

Signed-off-by: Ivan Vagin <ivan.vagin@samsung.com>
5 years agoFix pylint warning in image importer (#5631)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Mon, 15 Jul 2019 04:36:06 +0000 (13:36 +0900)]
Fix pylint warning in image importer (#5631)

Fix pylint warning for print syntax in image importer

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
5 years agoFix pylint warning in weight extract tool (#5629)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Mon, 15 Jul 2019 01:25:01 +0000 (10:25 +0900)]
Fix pylint warning in weight extract tool (#5629)

Fix pylint warning for print syntax in weight extract tool

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
5 years agoFix pylint warning in summarize pb file tool (#5630)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Fri, 12 Jul 2019 06:44:15 +0000 (15:44 +0900)]
Fix pylint warning in summarize pb file tool (#5630)

Fix pylint warning (anomalous backslash) in summarize pb file tool by attaching "r" prefix

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
5 years agoIntroduce pylint command (#5628)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Fri, 12 Jul 2019 05:01:37 +0000 (14:01 +0900)]
Introduce pylint command (#5628)

Introduce pylint command with custom warning policy
Except external codes (using file format deny .FORMATDENY)

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
5 years agoCopy template makefile in standalone scripts (#5618)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Fri, 12 Jul 2019 02:39:21 +0000 (11:39 +0900)]
Copy template makefile in standalone scripts (#5618)

* Copy template makefile in standalone scripts

Make Makefile by copying Makefile.template with -nv option and build in standalone scripts and nnfw.spec

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
* Fix command

5 years agoCalculate same padding using IFM shape (#5535)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Thu, 11 Jul 2019 10:00:11 +0000 (19:00 +0900)]
Calculate same padding using IFM shape (#5535)

Divide same padding size calculatation using IFM shape only, and check OFM shape validation.
Divided function may be used to calculate same padding size with unspecified OFM shape.

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
5 years agoIntroduce global ConfigSource interface (#5617)
이한종/On-Device Lab(SR)/Engineer/삼성전자 [Thu, 11 Jul 2019 09:28:48 +0000 (18:28 +0900)]
Introduce global ConfigSource interface (#5617)

* Introduce global ConfigSource interface

Have a global `IConfigSource` which can be replaced by a global
function. By doing this, neurun core can only read(get) the value and
values can be set from outside of neurun core.

Signed-off-by: Hanjoung Lee <hanjoung.lee@samsung.com>
* Fix initialization

* Handle default values

5 years agoFix pylint warning in tflitefile_tool (#5606)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Thu, 11 Jul 2019 06:14:35 +0000 (15:14 +0900)]
Fix pylint warning in tflitefile_tool (#5606)

Fix pylint warning in tflitefile_tool
- "dummy_" prefix for unused variable
- staticmethod keyword for static method
- Use sharp for comment instead of triple quote

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
5 years agoRemove makefile (#5595)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Thu, 11 Jul 2019 03:54:56 +0000 (12:54 +0900)]
Remove makefile (#5595)

* Remove makefile

Rename Makefile to Makefile.template to remove Makefile

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
* Update build script and gitignore list file

* Update template makefile and standalone scripts

5 years ago[nnfw_api] Prevent memory leakage in `nnfw_session::prepare` method (#5602)
Сергей Баранников/AI Tools Lab /SRR/Engineer/삼성전자 [Wed, 10 Jul 2019 10:05:18 +0000 (13:05 +0300)]
[nnfw_api] Prevent memory leakage in `nnfw_session::prepare` method (#5602)

Use `make_unique` to ensure memory is freed in case of exception.

Signed-off-by: Sergei Barannikov <s.barannikov@samsung.com>
5 years ago[nnpackage] Rename tensorflow lite's names (#5613)
이상규/On-Device Lab(SR)/Principal Engineer/삼성전자 [Wed, 10 Jul 2019 10:04:27 +0000 (19:04 +0900)]
[nnpackage] Rename tensorflow lite's names (#5613)

namespace, file_identifier and file_extension are renamed.
our copyright is pretended.
revision history has only 1 line (for version 0).

Signed-off-by: Sanggyu Lee <sg5.lee@samsung.com>
5 years agoUpdate git ignore file (#5596)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Wed, 10 Jul 2019 08:26:51 +0000 (17:26 +0900)]
Update git ignore file (#5596)

Cleanup .gitignore file to manage files generated by official tool only

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
5 years ago[nnpackage] add missing semicolon from nnpackage schema (#5612)
이상규/On-Device Lab(SR)/Principal Engineer/삼성전자 [Wed, 10 Jul 2019 06:09:35 +0000 (15:09 +0900)]
[nnpackage] add missing semicolon from nnpackage schema (#5612)

Add missing semicolon at end of `DataFormat`.

Signed-off-by: Sanggyu Lee <sg5.lee@samsung.com>
5 years ago[neurun] ACL CL kernel generation functionality moved into KernelGenerator (#5584)
Ivan Vagin/AI Tools Lab /SRR/Engineer/삼성전자 [Wed, 10 Jul 2019 05:22:15 +0000 (08:22 +0300)]
[neurun] ACL CL kernel generation functionality moved into KernelGenerator (#5584)

ACL CL kernel generation functionality moved from StageGenerator into KernelGenerator

Signed-off-by: Ivan Vagin <ivan.vagin@samsung.com>
5 years ago[neurun] ACL NEON kernel generation functionality moved into KernelGenerator (#5583)
Ivan Vagin/AI Tools Lab /SRR/Engineer/삼성전자 [Wed, 10 Jul 2019 05:22:03 +0000 (08:22 +0300)]
[neurun] ACL NEON kernel generation functionality moved into KernelGenerator (#5583)

ACL NEON kernel generation functionality moved from StageGenerator into KernelGenerator

Signed-off-by: Ivan Vagin <ivan.vagin@samsung.com>
5 years ago[neurun] CPU kernel generation functionality moved into KernelGenerator (#5582)
Ivan Vagin/AI Tools Lab /SRR/Engineer/삼성전자 [Wed, 10 Jul 2019 05:21:53 +0000 (08:21 +0300)]
[neurun] CPU kernel generation functionality moved into KernelGenerator (#5582)

CPU kernel generation functionality moved from StageGenerator into KernelGenerator

Signed-off-by: Ivan Vagin <ivan.vagin@samsung.com>
5 years agoImplement nnfw_run,set_input,set_output (#5605)
이춘석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Wed, 10 Jul 2019 02:17:18 +0000 (11:17 +0900)]
Implement nnfw_run,set_input,set_output (#5605)

- Implement nnfw_run, nnfw_set_input, nnfw_set_output

Signed-off-by: Chunseok Lee <chunseok.lee@samsung.com>
5 years ago[neurun] [nnapi] Meaningful exception message (#5603)
Vladimir Plazun/AI Tools Lab /SRR/Engineer/삼성전자 [Wed, 10 Jul 2019 02:09:27 +0000 (05:09 +0300)]
[neurun] [nnapi] Meaningful exception message (#5603)

* [neurun] [nnapi] Meaningful exception message

Throw exception with meaningful description in case of unsupported operation

Signed-off-by: Vladimir Plazun <v.plazun@samsung.com>
* Format fix

Signed-off-by: Vladimir Plazun <v.plazun@samsung.com>
5 years agoFix tflite loader build bug (#5594)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Tue, 9 Jul 2019 10:11:19 +0000 (19:11 +0900)]
Fix tflite loader build bug (#5594)

Build tflite loader tool when neurun is built

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
5 years agoImplement nnfw_prepare (#5585)
이춘석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Tue, 9 Jul 2019 09:59:48 +0000 (18:59 +0900)]
Implement nnfw_prepare (#5585)

* Implement nnfw_prepare

- Add implementation for nnfw_prepare

Signed-off-by: Chunseok Lee <chunseok.lee@samsung.com>
* delete compiler after compile

5 years agoMove tflite loader (#5589)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Tue, 9 Jul 2019 09:43:02 +0000 (18:43 +0900)]
Move tflite loader (#5589)

- Move tflite loader into neurun/frontend
- Move tflite loader tool to tests/tools

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
5 years agoMove ConfigManager.cc to the upper directory (#5586)
이한종/On-Device Lab(SR)/Engineer/삼성전자 [Tue, 9 Jul 2019 06:46:30 +0000 (15:46 +0900)]
Move ConfigManager.cc to the upper directory (#5586)

`ConfigManager.cc` should have been moved to the upper directory from
PR #5555 but it wasn't. So this commit fixes it.

Signed-off-by: Hanjoung Lee <hanjoung.lee@samsung.com>
5 years agoRemove externals/.FORMATDENY file (#5587)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Tue, 9 Jul 2019 05:11:35 +0000 (14:11 +0900)]
Remove externals/.FORMATDENY file (#5587)

Remove remain externals/.FORMATDENY file in external to remove externals directory in repo
Make directory in nnfw.spec to copy saved external code

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
5 years agoMove script for generate test (#5578)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Tue, 9 Jul 2019 04:27:32 +0000 (13:27 +0900)]
Move script for generate test (#5578)

Move script in externals/nnapi_test_generator to generate nnapi gtest
Update gitignore - remove deprecated directory

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
5 years agoMove lcov-to-cobertura-xml script (#5580)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Tue, 9 Jul 2019 04:27:16 +0000 (13:27 +0900)]
Move lcov-to-cobertura-xml script (#5580)

Move externals/lcov-to-cobertura-xml directory to tools/
Remove external tool dependency in gen-coverage-report command

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
5 years ago[nnpackage] update specification to add model-types attribute (#5572)
이상규/On-Device Lab(SR)/Principal Engineer/삼성전자 [Tue, 9 Jul 2019 04:12:56 +0000 (13:12 +0900)]
[nnpackage] update specification to add model-types attribute (#5572)

`MANIFEST` will have `model-types` attributes to identify what kind of
models it contins.

Signed-off-by: Sanggyu Lee <sg5.lee@samsung.com>
5 years ago[neurun] Initial implementation of KernelGenerator (#5574)
Ivan Vagin/AI Tools Lab /SRR/Engineer/삼성전자 [Mon, 8 Jul 2019 10:16:37 +0000 (13:16 +0300)]
[neurun] Initial implementation of KernelGenerator (#5574)

* Implementated KernelGenerator interface
* Implemented empty KernelGenerator classes for each backend

Signed-off-by: Ivan Vagin <ivan.vagin@samsung.com>
5 years agoRemove CMAKE_SOURCE_DIR in cmake script (#5576)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Mon, 8 Jul 2019 08:18:37 +0000 (17:18 +0900)]
Remove CMAKE_SOURCE_DIR in cmake script (#5576)

- Change CMAKE_SOURCE_DIR/externals to NNFW_EXTERNALS_DIR
- Remove some target_include_directories using CMAKE_SOURCE_DIR: because of linked libraries already include with PUBLIC

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
5 years ago[tflite_loader] Perform tflite_loader tests while testing neurun cpu (#5526)
Ivan Vagin/AI Tools Lab /SRR/Engineer/삼성전자 [Mon, 8 Jul 2019 05:56:29 +0000 (08:56 +0300)]
[tflite_loader] Perform tflite_loader tests while testing neurun cpu (#5526)

Perform tflite_loader tests while testing neurun cpu

Signed-off-by: Ivan Vagin <ivan.vagin@samsung.com>
5 years agoRemove mobilenet tests in nnapi generated test (#5554)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Mon, 8 Jul 2019 04:50:45 +0000 (13:50 +0900)]
Remove mobilenet tests in nnapi generated test (#5554)

Comment out mobilenet recipes in nnapi generated test

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
5 years agoDecouple ConfigManager with Env Vars (#5565)
이한종/On-Device Lab(SR)/Engineer/삼성전자 [Fri, 5 Jul 2019 10:58:01 +0000 (19:58 +0900)]
Decouple ConfigManager with Env Vars (#5565)

- `IConfigSource` is introduced
- `ConfigManager` gets value through `IConfigSource`
- `EnvConfigSource` is a subclass of `IConfgSource` that gets values
  from Env Vars

Resolve #5556

Signed-off-by: Hanjoung Lee <hanjoung.lee@samsung.com>
5 years agoImplement nnfw_load_model_from_file (#5533)
이춘석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Fri, 5 Jul 2019 06:11:32 +0000 (15:11 +0900)]
Implement nnfw_load_model_from_file (#5533)

- accept nnpackge directory as argument.

Signed-off-by: Chunseok Lee <chunseok.lee@samsung.com>
5 years ago[tflite_loader] Supported models with multiple output tensors (#5525)
Ivan Vagin/AI Tools Lab /SRR/Engineer/삼성전자 [Fri, 5 Jul 2019 01:17:18 +0000 (04:17 +0300)]
[tflite_loader] Supported models with multiple output tensors (#5525)

* [tflite_loader] Supported models with multiple output tensors

Supported models with multiple output tensors

Signed-off-by: Ivan Vagin <ivan.vagin@samsung.com>
5 years ago[nnpackage] update spec for multiple layout (#5553)
이상규/On-Device Lab(SR)/Principal Engineer/삼성전자 [Fri, 5 Jul 2019 01:15:45 +0000 (10:15 +0900)]
[nnpackage] update spec for multiple layout (#5553)

Multiple layout is added in specification.

Signed-off-by: Sanggyu Lee <sg5.lee@samsung.com>
5 years ago[kbenchmark] Add TransposeConv kernel (#5546)
윤지영/On-Device Lab(SR)/Staff Engineer/삼성전자 [Thu, 4 Jul 2019 10:08:40 +0000 (19:08 +0900)]
[kbenchmark] Add TransposeConv kernel (#5546)

This patch adds acl cl and neon TransposeConv kernel test sets.
It also tests CLDeconvolutionLayerEx.

Signed-off-by: Jiyoung Yun <jy910.yun@samsung.com>
5 years ago[neurun] Applied shape fixer (#5549)
Ivan Vagin/AI Tools Lab /SRR/Engineer/삼성전자 [Thu, 4 Jul 2019 09:59:38 +0000 (12:59 +0300)]
[neurun] Applied shape fixer (#5549)

Applied ShapeFixer, removed ShapeFixer functionality from StageGenerator

Signed-off-by: Ivan Vagin <ivan.vagin@samsung.com>
5 years ago[tflite_loader] Generate smaller values for input tensors (#5538)
Ivan Vagin/AI Tools Lab /SRR/Engineer/삼성전자 [Thu, 4 Jul 2019 02:21:17 +0000 (05:21 +0300)]
[tflite_loader] Generate smaller values for input tensors (#5538)

Generate smaller values for input tensors

Signed-off-by: Ivan Vagin <ivan.vagin@samsung.com>
5 years agoSpecify parameter types in nnfw.h comments (#5550)
이한종/On-Device Lab(SR)/Engineer/삼성전자 [Thu, 4 Jul 2019 01:55:30 +0000 (10:55 +0900)]
Specify parameter types in nnfw.h comments (#5550)

Specify parameter type for every param comments  whether it is 'in' or
'out'.

Signed-off-by: Hanjoung Lee <hanjoung.lee@samsung.com>
5 years agoUpdate root cmake script (#5552)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Thu, 4 Jul 2019 01:46:51 +0000 (10:46 +0900)]
Update root cmake script (#5552)

- Change require minimum cmake version to 3.5.1 (ubuntu 16.04)
- Don't use gnu++11 extension
- Introduce overlay for external pre-built and install (from star/nncc#2838)

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
5 years agoFix build error in ShapeInference test (#5563)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Thu, 4 Jul 2019 01:13:43 +0000 (10:13 +0900)]
Fix build error in ShapeInference test (#5563)

Fix build error by updated model.operands - ObjectManager

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
5 years ago[neurun] Initial implementation of ShapeInference component (#5363)
Ivan Vagin/AI Tools Lab /SRR/Engineer/삼성전자 [Thu, 4 Jul 2019 00:45:50 +0000 (03:45 +0300)]
[neurun] Initial implementation of ShapeInference component (#5363)

* [neurun] Initial implementation of ShapeInference component

* Added initial implementation of ShapeInference component
* Implemented ShapeInference visitor for AddOp
* Implemented ShapeInference unit tests for AddOp

Signed-off-by: Ivan Vagin <ivan.vagin@samsung.com>
* Moved to utils

Signed-off-by: Ivan Vagin <ivan.vagin@samsung.com>
5 years agoChange namespace of ConfigManager (#5555)
이한종/On-Device Lab(SR)/Engineer/삼성전자 [Thu, 4 Jul 2019 00:37:03 +0000 (09:37 +0900)]
Change namespace of ConfigManager (#5555)

- namespace : `neurun::config` -> `neurun::util`
- directory : `util/config` -> `util`

const strings stay in namepace `neurun::util::config`.

Signed-off-by: Hanjoung Lee <hanjoung.lee@samsung.com>
5 years agoCorrect a typo in nnfw.h (#5548)
이한종/On-Device Lab(SR)/Engineer/삼성전자 [Wed, 3 Jul 2019 09:53:04 +0000 (18:53 +0900)]
Correct a typo in nnfw.h (#5548)

This commit corrects typo : pacakge to package.

Signed-off-by: Hanjoung Lee <hanjoung.lee@samsung.com>
5 years ago[nnpackage] Update specification (model_and_operators) (#5529)
이상규/On-Device Lab(SR)/Principal Engineer/삼성전자 [Wed, 3 Jul 2019 09:32:00 +0000 (18:32 +0900)]
[nnpackage] Update specification (model_and_operators) (#5529)

* [nnpackage] Update specification (model_and_operators)

Added:

- Serialization Format
- Baseline Schema
- Unspecified dimension

* Remove rationale for serialization format

5 years agoFix arm compute cl kernel for transpose conv (#5543)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Wed, 3 Jul 2019 09:29:03 +0000 (18:29 +0900)]
Fix arm compute cl kernel for transpose conv (#5543)

* Fix arm compute cl kernel for transpose conv

Fix arm compute cl kernel for transpose conv
- Padding calculation
- Allow asymmetric padding
- Get and fix upsample layer and kernel
- Rename DeconvolutionXXX to TransposeConvXXX
- Enable all transpose conv tests

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
* Fix pacl

5 years agoIntroduce NNFW_EXTERNALS_DIR configuration (#5544)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Wed, 3 Jul 2019 08:00:39 +0000 (17:00 +0900)]
Introduce NNFW_EXTERNALS_DIR configuration (#5544)

This commit allows users to download external dependencies
into their own location via setting NNFW_EXTERNALS_DIR.
Same with nncc: star/nncc#4065

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
5 years agoAdd minor scheduler related fixes (#5479)
Дилшоджон Умронхонович Пошшоев/AI Tools Lab /SRR/Engineer/삼성전자 [Wed, 3 Jul 2019 07:52:52 +0000 (10:52 +0300)]
Add minor scheduler related fixes (#5479)

* Add minor scheduler related fixes

1. No need to call notifyJobBegin/End for non-profiling run
2. Just one of the scheduler must be called

Signed-off-by: Poshshoev Dilshodzhon <d.poshshoev@samsung.com>
* Fix Scheduler issues

Signed-off-by: Poshshoev Dilshodzhon <d.poshshoev@samsung.com>
* Revert changes in DataflowExecutor::executeImpl

Signed-off-by: Poshshoev Dilshodzhon <d.poshshoev@samsung.com>
5 years ago[neurun] Introduced ShapeFixer (#5521)
Ivan Vagin/AI Tools Lab /SRR/Engineer/삼성전자 [Wed, 3 Jul 2019 07:51:41 +0000 (10:51 +0300)]
[neurun] Introduced ShapeFixer (#5521)

* [neurun] Introduced ShapeFixer

Introduced ShapeFixer component in neurun Backends

Signed-off-by: Ivan Vagin <ivan.vagin@samsung.com>
* Review fixes

Signed-off-by: Ivan Vagin <ivan.vagin@samsung.com>
5 years agoFix and add license (#5537)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Wed, 3 Jul 2019 07:28:03 +0000 (16:28 +0900)]
Fix and add license (#5537)

Fix license year and add lost license

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
5 years agoEnable tflite_loader on gbs build (#5536)
이춘석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Wed, 3 Jul 2019 07:27:03 +0000 (16:27 +0900)]
Enable tflite_loader on gbs build (#5536)

- Note that tizen does not have flatbuffer repo
- This patch enables tflite_loader build on gbs
- flatbuffer source commit : 1f5eae5d6a135

Signed-off-by: Chunseok Lee <chunseok.lee@samsung.com>
5 years agoUpdate README (#5528)
이성재/On-Device Lab(SR)/Principal Engineer/삼성전자 [Wed, 3 Jul 2019 05:59:14 +0000 (14:59 +0900)]
Update README (#5528)

* Update README

- Add `Maintainers` and `Committers` list to following the rule of Samsung
Inner Source Program.

Signed-off-by: Sung-Jae Lee <sj925.lee@samsung.com>
* Update committers list

- Add Hanjoung Lee instead Seihie Park.

Signed-off-by: Sung-Jae Lee <sj925.lee@samsung.com>
5 years agoAdd transpose conv tflite file test (#5541)
오형석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Wed, 3 Jul 2019 05:52:59 +0000 (14:52 +0900)]
Add transpose conv tflite file test (#5541)

Add transpose conv tensorflow lite file test (framework test) - same padding, stride 2

Signed-off-by: Hyeongseok Oh <hseok82.oh@samsung.com>
5 years ago[kbenchmark] Update summary view of html file (#5519)
윤지영/On-Device Lab(SR)/Staff Engineer/삼성전자 [Tue, 2 Jul 2019 10:03:37 +0000 (19:03 +0900)]
[kbenchmark] Update summary view of html file (#5519)

* [kbenchmark] Update summary view of html file

This patch generates a summary view of html file.
This will help you to see at a glance which graph shows
which kernel performs well in the current layer.

Signed-off-by: Jiyoung Yun <jy910.yun@samsung.com>
* Change the location of the html_report_template.g.h++ that needs copy to cmake/packages/Nonius directory

5 years agoAdd CONTRIBTUTORS file (#5517)
이성재/On-Device Lab(SR)/Principal Engineer/삼성전자 [Tue, 2 Jul 2019 07:20:17 +0000 (16:20 +0900)]
Add CONTRIBTUTORS file (#5517)

- Add contributor list, as is.
- Generated by `git shortlog -se | cut -f2` with `.mailmap` file.

Signed-off-by: Sung-Jae Lee <sj925.lee@samsung.com>
5 years agoDefine Operations with ObjectManager (#5508)
이한종/On-Device Lab(SR)/Engineer/삼성전자 [Tue, 2 Jul 2019 07:11:03 +0000 (16:11 +0900)]
Define Operations with ObjectManager (#5508)

Just like `Operands` were defined as an ObjectManager specialization,
this applies the same for `Operations`.

See also : #5464

Signed-off-by: Hanjoung Lee <hanjoung.lee@samsung.com>
5 years agonnfw API implementation skeleton (#5527)
이춘석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Tue, 2 Jul 2019 05:33:28 +0000 (14:33 +0900)]
nnfw API implementation skeleton (#5527)

- c++ wrapper for nnfw.h in api/wrapper
- empty implementation

Signed-off-by: Chunseok Lee <chunseok.lee@samsung.com>
5 years agoRemove `model::Shape::asVector` replacing calls to it with `num_elements()` or `dim...
Сергей Баранников/AI Tools Lab /SRR/Engineer/삼성전자 [Tue, 2 Jul 2019 04:56:48 +0000 (07:56 +0300)]
Remove `model::Shape::asVector` replacing calls to it with `num_elements()` or `dim(0)`. (#5498)

Also remove unused `model::Shape::asMatrix` and `model::Shape::asTensor`.

This is a preparation step before removing dependency of `model::Shape` on `misc::tensor::Shape`.

Signed-off-by: Sergei Barannikov <s.barannikov@samsung.com>
5 years agoUpload exec_time explicitely, not in destructor (#5511)
Дилшоджон Умронхонович Пошшоев/AI Tools Lab /SRR/Engineer/삼성전자 [Tue, 2 Jul 2019 01:41:59 +0000 (04:41 +0300)]
Upload exec_time explicitely, not in destructor (#5511)

Since exec time is updated just in case of turned on profiler, no need
to upload it in a destructor. Moreover, since graph::Graph is reusable,
in its next usages BackendResolver will be recreated without destructing
JSON/ExecTime/Graph, so Backend, that is pointed by
JSON::_measurements.first in the first call is destructed and
JSON::uploadOperationsExecTime will cause a segmentation error in
`printString(backend.first->config()->id(), stream);`

Signed-off-by: Poshshoev Dilshodzhon <d.poshshoev@samsung.com>
5 years agoAdd workarounds for unsupported ops in scheduler (#5512)
Дилшоджон Умронхонович Пошшоев/AI Tools Lab /SRR/Engineer/삼성전자 [Tue, 2 Jul 2019 01:32:59 +0000 (04:32 +0300)]
Add workarounds for unsupported ops in scheduler (#5512)

This is workaround, come up with better solution if have.
Adding exception in stage doesn't help. Because if
there is a record for an op without broadcast,
scheduling will select it since it doesn't distinguish
broadcast and non-broadcast like it does for quant&non-quantized

Signed-off-by: Poshshoev Dilshodzhon <d.poshshoev@samsung.com>
5 years agoAdd header files to use tflite_loader (#5520)
이춘석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Tue, 2 Jul 2019 01:26:42 +0000 (10:26 +0900)]
Add header files to use tflite_loader (#5520)

- provide header files to build with tflite_loader

Signed-off-by: Chunseok Lee <chunseok.lee@samsung.com>
5 years agoUse CLRsqrtLayer instead of custom implementation (#5500)
Сергей Баранников/AI Tools Lab /SRR/Engineer/삼성전자 [Mon, 1 Jul 2019 10:28:00 +0000 (13:28 +0300)]
Use CLRsqrtLayer instead of custom implementation (#5500)

Use `CLRsqrtLayer` (introduced in ACL v19.02) instead of custom implementation

Signed-off-by: Sergei Barannikov <s.barannikov@samsung.com>
5 years agoUse CLExpLayer instead of custom implementation (#5501)
Сергей Баранников/AI Tools Lab /SRR/Engineer/삼성전자 [Mon, 1 Jul 2019 10:27:19 +0000 (13:27 +0300)]
Use CLExpLayer instead of custom implementation (#5501)

Use `CLExpLayer` (introduced in ACL v19.02) instead of custom implementation

Signed-off-by: Sergei Barannikov <s.barannikov@samsung.com>
5 years agoUse CLElementwiseSquaredDiff instead of custom implementation (#5502)
Сергей Баранников/AI Tools Lab /SRR/Engineer/삼성전자 [Mon, 1 Jul 2019 10:26:43 +0000 (13:26 +0300)]
Use CLElementwiseSquaredDiff instead of custom implementation (#5502)

Use `CLElementwiseSquaredDiff` (introduced in ACL v19.02) instead of custom implementation

Signed-off-by: Sergei Barannikov <s.barannikov@samsung.com>
5 years agoAssign 1 to supported op in Scheduler::tryBackend (#5490)
Дилшоджон Умронхонович Пошшоев/AI Tools Lab /SRR/Engineer/삼성전자 [Mon, 1 Jul 2019 10:19:02 +0000 (13:19 +0300)]
Assign 1 to supported op in Scheduler::tryBackend (#5490)

Scheduler must prefer supported op to unsupported one

Signed-off-by: Poshshoev Dilshodzhon <d.poshshoev@samsung.com>
5 years agojsoncpp library as a static lib for nnfw internal use (#5510)
이춘석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Mon, 1 Jul 2019 08:24:34 +0000 (17:24 +0900)]
jsoncpp library as a static lib for nnfw internal use (#5510)

* jsoncpp library as a static lib for nnfw internal use

- jsoncpp library(1.7.7) as a static lib
- tizen does not provide static lib and it is not sure that it is
- shipped into tizen platform

Signed-off-by: Chunseok Lee <chunseok.lee@samsung.com>
* apply format.patch

5 years ago[neurun] Fix multiple parent tensor skipping (#5509)
Ivan Vagin/AI Tools Lab /SRR/Engineer/삼성전자 [Mon, 1 Jul 2019 04:58:00 +0000 (07:58 +0300)]
[neurun] Fix multiple parent tensor skipping (#5509)

Fix multiple parent tensor skipping

Signed-off-by: Ivan Vagin <ivan.vagin@samsung.com>
5 years ago[kbenchmark] Separate the result file if it is not html reporter type (#5361)
윤지영/On-Device Lab(SR)/Staff Engineer/삼성전자 [Mon, 1 Jul 2019 03:44:43 +0000 (12:44 +0900)]
[kbenchmark] Separate the result file if it is not html reporter type (#5361)

This patch separates the result files if it is not html reporter type.
Becuase other reporters store only one test result in one file.

Signed-off-by: Jiyoung Yun <jy910.yun@samsung.com>
5 years agoDefine minial NNFW API (#5463)
이춘석/On-Device Lab(SR)/Staff Engineer/삼성전자 [Thu, 27 Jun 2019 05:40:13 +0000 (14:40 +0900)]
Define minial NNFW API (#5463)

* Define minial NNFW API

- define a minimal set of runtiem API

Signed-off-by: Chunseok Lee <chunseok.lee@samsung.com>
* remove meta info getter

5 years ago[nnpackage] Modify main-model to models to support multiple models (#5486)
이상규/On-Device Lab(SR)/Principal Engineer/삼성전자 [Thu, 27 Jun 2019 04:46:58 +0000 (13:46 +0900)]
[nnpackage] Modify main-model to models to support multiple models (#5486)

For multiple model support in future, main-model is changed to models.
`models` is an array of model paths.

Signed-off-by: Sanggyu Lee <sg5.lee@samsung.com>
5 years ago[customOp] Added a figure for workflow (#5495)
윤현식/On-Device Lab(SR)/Principal Engineer/삼성전자 [Thu, 27 Jun 2019 04:27:35 +0000 (13:27 +0900)]
[customOp] Added a figure for workflow (#5495)

* [customOp] added a figure for workflow

This adds a figure for workflow to prepare a model with custom operation.

Signed-off-by: Hyun Sik Yoon <hyunsik.yoon@samsung.com>
* revised diagram

5 years agoFix build of PACL (#5499)
Сергей Баранников/AI Tools Lab /SRR/Engineer/삼성전자 [Thu, 27 Jun 2019 00:56:31 +0000 (03:56 +0300)]
Fix build of PACL (#5499)

Fix failing build of PACL caused by #5492

Signed-off-by: Sergei Barannikov <s.barannikov@samsung.com>
5 years agoFix rank calculation in executors (#5480)
Дилшоджон Умронхонович Пошшоев/AI Tools Lab /SRR/Engineer/삼성전자 [Thu, 27 Jun 2019 00:50:46 +0000 (03:50 +0300)]
Fix rank calculation in executors (#5480)

Assign either rank or zero if there isn't any like in notify()
Also moved calculateRank into DataflowExecutor

Signed-off-by: Poshshoev Dilshodzhon <d.poshshoev@samsung.com>
5 years agoUse polymorphic_downcast instead of dynamic_cast. (#5493)
Сергей Баранников/AI Tools Lab /SRR/Engineer/삼성전자 [Wed, 26 Jun 2019 09:47:50 +0000 (12:47 +0300)]
Use polymorphic_downcast instead of dynamic_cast. (#5493)

Use `polymorphic_downcast` instead of `dynamic_cast` to avoid unnecessary overhead as was suggested in https://github.sec.samsung.net/STAR/nnfw/pull/5383#discussion_r200703.
Remove several redundant `dynamic_cast`s.

Signed-off-by: Sergei Barannikov <s.barannikov@samsung.com>
5 years ago[kbenchmark] Add filter option (#5360)
윤지영/On-Device Lab(SR)/Staff Engineer/삼성전자 [Wed, 26 Jun 2019 09:39:06 +0000 (18:39 +0900)]
[kbenchmark] Add filter option (#5360)

This option allows to run benchmark whose name matches the regex.

Signed-off-by: Jiyoung Yun <jy910.yun@samsung.com>
5 years ago[neurun] fix ExecutorBase::getOutput() (#5494)
Vladimir Plazun/AI Tools Lab /SRR/Engineer/삼성전자 [Wed, 26 Jun 2019 09:36:10 +0000 (12:36 +0300)]
[neurun] fix ExecutorBase::getOutput() (#5494)

ExecutorBase::getOutput() was using model->inputs instead of  outputs

Signed-off-by: Vladimir Plazun <v.plazun@samsung.com>
5 years ago[nnpackage] Add version attribute in manifest (#5484)
이상규/On-Device Lab(SR)/Principal Engineer/삼성전자 [Wed, 26 Jun 2019 09:27:28 +0000 (18:27 +0900)]
[nnpackage] Add version attribute in manifest (#5484)

* [nnpackage] Add version attribute in manifest

Introduce major-version, minor-version, patch-version.

Signed-off-by: Sanggyu Lee <sg5.lee@samsung.com>
* Remove the word `API` used in `version` attribute

5 years agoRename element_nums to num_elements (#5492)
Сергей Баранников/AI Tools Lab /SRR/Engineer/삼성전자 [Wed, 26 Jun 2019 06:47:09 +0000 (09:47 +0300)]
Rename element_nums to num_elements (#5492)

Rename `element_nums` methods of `ITensor` and `Shape` classes to more appropriate `num_elements`.
Reuse `num_elements` in several places to reduce code duplication.

Signed-off-by: Sergei Barannikov <s.barannikov@samsung.com>
5 years ago[neurun] Fix kernel shapes for Conv2D and DepthwiseConv2D (#5461)
Сергей Баранников/AI Tools Lab /SRR/Engineer/삼성전자 [Wed, 26 Jun 2019 06:46:26 +0000 (09:46 +0300)]
[neurun] Fix kernel shapes for Conv2D and DepthwiseConv2D (#5461)

* [neurun] Fix kernel shapes for Conv2D and DepthwiseConv2D

* Remove `neurun::model::Shape::asKernel`
* Remove similar no longer used method `asMatrix`
* Remove redundant and not used method `asTensor`

Signed-off-by: Sergei Barannikov <s.barannikov@samsung.com>
* * Revert some unrelated changes.

Signed-off-by: Sergei Barannikov <s.barannikov@samsung.com>