platform/core/api/mediavision.git
14 months agomv_machine_learning: fix coverity issues 51/289951/1 accepted/tizen/unified/20230316.174023
Inki Dae [Thu, 16 Mar 2023 04:39:47 +0000 (13:39 +0900)]
mv_machine_learning: fix coverity issues

[Version] : 0.27.5
[Issue type] : bug fix

Fixed coverity issues, DIVIDE_BY_ZERO.

Change-Id: I87311ac7c527ae6ac8d54ef5433b5b591bf6daf3
Signed-off-by: Inki Dae <inki.dae@samsung.com>
14 months agomv_machine_learning: fix svace issues 40/289940/2
Inki Dae [Thu, 16 Mar 2023 01:54:50 +0000 (10:54 +0900)]
mv_machine_learning: fix svace issues

[Version] : 0.27.4
[Issue type] : bug fix

Fixed svace issues, SIGN_EXTENSION.
write function of std::ofstream class and read function
of std::ifstream class need streamsize type as the type of
second parameter so cast existing size_t type to streamsize one.

Change-Id: I54ea59aa9935500242ca7423859a5d158b3743d9
Signed-off-by: Inki Dae <inki.dae@samsung.com>
15 months agoMerge branch 'tizen_devel' into tizen accepted/tizen/unified/20230303.162803
Kwanghoon Son [Fri, 3 Mar 2023 08:12:48 +0000 (17:12 +0900)]
Merge branch 'tizen_devel' into tizen

[Version] 0.27.3

Inki Dae (8):
  mv_machine_learning: code refactoring to object detection task group
  mv_machine_learning: rename 'output' to 'tensor'
  mv_machine_learning: rename 'getResult()' to 'result()'
  mv_machine_learning: use carnel notation
  mv_machine_learning: drop dead code
  mv_machine_learning: separate object detection group
  mv_machine_learning: update mobilenet v1 ssd model support
  mv_machine_learning: fix mutex bug

Kwanghoon Son (2):
  Add DesignQR embed logo image
  Add logo shape

Tae-Young Chung (2):
  Add movenet models to mv_test
  Add LICENSE.BSD-3-Clause

Change-Id: I6e15ea4a172e2382087ce0ebee096605cf6e4630
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
15 months agoAdd LICENSE.BSD-3-Clause
Tae-Young Chung [Thu, 2 Mar 2023 09:16:46 +0000 (18:16 +0900)]
Add LICENSE.BSD-3-Clause

[Issue type] : update

Change-Id: I446e7e0a4248352816c93ba9acfabd01b28bd52f
Signed-off-by: Tae-Young Chung <ty83.chung@samsung.com>
15 months agomv_machine_learning: fix mutex bug
Inki Dae [Tue, 28 Feb 2023 02:25:54 +0000 (11:25 +0900)]
mv_machine_learning: fix mutex bug

[Issue type] : bug fix

Fixed a mutex bug that race condition to context object happens due to using
a mutex per context. Context object should also be protected by mutex so
use a task group specific mutex instead of a mutex per a context.

Change-Id: I468d835f3758a905453c32124a75335de6bc8f8a
Signed-off-by: Inki Dae <inki.dae@samsung.com>
15 months agoAdd logo shape
Kwanghoon Son [Fri, 24 Feb 2023 04:23:10 +0000 (13:23 +0900)]
Add logo shape

The shape of the logo image is changed according to the shape
of the qrcode finder.

Change-Id: Id8020ee208babd9409b099e53912e453245e5810
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
15 months agomv_machine_learning: update mobilenet v1 ssd model support
Inki Dae [Wed, 15 Feb 2023 08:22:18 +0000 (17:22 +0900)]
mv_machine_learning: update mobilenet v1 ssd model support

[Issue type] : new feature

Updated mobilenet v1 ssd model for itask based object detection group.

With this patch, we introduce new three CAPI - using only standard data type -
for getting the object detection result and for setting user-given model, and
renamed mobilenet_ssd.h/cpp to mobilenet_v1_ssd.h/cpp because each child class
of the task group is specific to its model.

Change-Id: I5cae3436be028f9a38813883b8ed0c7836eb25f6
Signed-off-by: Inki Dae <inki.dae@samsung.com>
15 months agoAdd DesignQR embed logo image
Kwanghoon Son [Thu, 16 Feb 2023 09:27:08 +0000 (18:27 +0900)]
Add DesignQR embed logo image

QRcode generate MV_BARCODE_GENERATE_ATTR_EMBED_IMG_PATH and it's size
will be 1/5 of output image. This will 4% of total image size so ok with
qrcode ecc recovery.

Change-Id: I9bf902cada3d7a03d7dff424b676bb7344968b2a
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
15 months agoAdd movenet models to mv_test
Tae-Young Chung [Thu, 16 Feb 2023 07:31:50 +0000 (16:31 +0900)]
Add movenet models to mv_test

[Issue type]: update

Change-Id: I36b698218909a73db54114079f577c9ba1a9fac8
Signed-off-by: Tae-Young Chung <ty83.chung@samsung.com>
15 months agomv_machine_learning: separate object detection group
Inki Dae [Tue, 14 Feb 2023 07:52:47 +0000 (16:52 +0900)]
mv_machine_learning: separate object detection group

[Issue type] : code refactoring

This is a code refactoring patch to separate existing object detection group
into two groups - object detection and object detection 3d groups.

We cannot combine these two groups with one because each group has default
model so in the use case that user uses object detection and object detection
3d model API together, one of them isn't allowed for the use.

So separate them into object detection and object detection 3d groups.
As for the object detection group, this patch provides only skeleton code
for mobilenet ssd model.

Change-Id: I97737ce07a07398a510e1f508608a8bdf24844cc
Signed-off-by: Inki Dae <inki.dae@samsung.com>
15 months agomv_machine_learning: drop dead code
Inki Dae [Tue, 14 Feb 2023 02:25:15 +0000 (11:25 +0900)]
mv_machine_learning: drop dead code

[Issue type] : code cleanup

Change-Id: If8ad0145e30b95776d891477fcebf72afd5150eb
Signed-off-by: Inki Dae <inki.dae@samsung.com>
15 months agomv_machine_learning: use carnel notation
Inki Dae [Tue, 14 Feb 2023 02:19:09 +0000 (11:19 +0900)]
mv_machine_learning: use carnel notation

[Issue type] : code cleanup

Change-Id: If99f9105d95055142a58ffeddc12386689aeb7c2
Signed-off-by: Inki Dae <inki.dae@samsung.com>
15 months agomv_machine_learning: rename 'getResult()' to 'result()'
Inki Dae [Mon, 13 Feb 2023 07:36:44 +0000 (16:36 +0900)]
mv_machine_learning: rename 'getResult()' to 'result()'

[Issue type] : code cleanup

Change-Id: I1f5d90736b7c11e6769f25d82eacd2297294a841
Signed-off-by: Inki Dae <inki.dae@samsung.com>
15 months agomv_machine_learning: rename 'output' to 'tensor'
Inki Dae [Mon, 13 Feb 2023 07:27:27 +0000 (16:27 +0900)]
mv_machine_learning: rename 'output' to 'tensor'

[Issue type] : code cleanup

Change-Id: Id68c76c5ddc46d13036ea163e19a5e52e54b181b
Signed-off-by: Inki Dae <inki.dae@samsung.com>
15 months agomv_machine_learning: code refactoring to object detection task group
Inki Dae [Fri, 10 Feb 2023 10:07:14 +0000 (19:07 +0900)]
mv_machine_learning: code refactoring to object detection task group

[Issue type] : code refactoring

This is a code refactoring patch for making object detection task group
to be more generic by doing,
   - rename internal API from object_detection_3d to object_detection
     excepting below three object detection 3d relevant API,
 mv_object_detection_3d_get_probability,
 mv_object_detection_3d_get_num_of_points,
 and mv_object_detection_3d_get_points_open.
   - use more generic prefix to definitions for configuration.
   - introduce getOutputNames() and getOutputTensors() functions for
     object detection group class, and make objectron class to use them
 instead of implementing there because they can be used commonly for
 other specific classes of the object detection group later.

Change-Id: Ic305d42a8b6fb16cae7d806264dd78499c59ee97
Signed-off-by: Inki Dae <inki.dae@samsung.com>
15 months agoExclude gcov test directory 90/288890/1
Kwanghoon Son [Fri, 24 Feb 2023 06:57:05 +0000 (15:57 +0900)]
Exclude gcov test directory

[Version] : 0.27.2
[Issue type] : Fix

Change-Id: I172fe5dc7b623ccd83a8f1c81d82116dab285bcb
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
15 months agomv_machine_learning: fix coverity issue 31/288731/1
Inki Dae [Wed, 22 Feb 2023 05:56:51 +0000 (14:56 +0900)]
mv_machine_learning: fix coverity issue

[Version] : 0.27.1
[Issue type] : bug fix

CID : 1656602

Drop the use of mutex lock in mv_face_recognition_destroy_open function.

Change-Id: Ib945c352709421891274ce720ed796707ee10a78
Signed-off-by: Inki Dae <inki.dae@samsung.com>
15 months agoMerge tizen_devel and version up to 0.27.0 accepted/tizen/unified/20230220.174431
Kwanghoon Son [Mon, 13 Feb 2023 02:32:50 +0000 (11:32 +0900)]
Merge tizen_devel and version up to 0.27.0

[Version] 0.27.0
[Issue type] sync

Inki Dae (3):
  mv_machine_learning: drop deprecated enum type
  mv_machine_learning: drop backbone model code dependency
  mv_machine_learning: introduce image classification task group

Kwanghoon Son (6):
  mv_barcode: clean duplicate code
  Fix format
  Add Design QR header and test
  Add design QR finder shape
  Add MV_BARCODE_GENERATE_ATTR_EMBED_IMG_PATH
  Add Design qr combination test

Seungbae Shin (1):
  Fix build warnings

Tae-Young Chung (1):
  Support new DFS_DATA_INPUT_FORMAT_COUPLED_TB

Change-Id: I147cddb4a2e1843474a7ff9bf867c4dc754df234
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
15 months agoAdd Design qr combination test
Kwanghoon Son [Fri, 3 Feb 2023 08:00:45 +0000 (17:00 +0900)]
Add Design qr combination test

Change-Id: I081b8495c4e2958cda735b75fb11fd6b537f720c
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
15 months agoAdd MV_BARCODE_GENERATE_ATTR_EMBED_IMG_PATH
Kwanghoon Son [Mon, 6 Feb 2023 03:12:00 +0000 (12:12 +0900)]
Add MV_BARCODE_GENERATE_ATTR_EMBED_IMG_PATH

MV_BARCODE_GENERATE_ATTR_EMBED_IMG_PATH is for embed image in middle of
qr code.

Change-Id: I01b25970344c0fc95e65ce39e12a0a4aa65d9317
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
15 months agoFix build warnings
Seungbae Shin [Tue, 7 Feb 2023 07:54:08 +0000 (16:54 +0900)]
Fix build warnings

[Issue type] : build

Change-Id: Ia1c2bfcdf50d39b61b8154e9bcca7f1dfc061029

15 months agoAdd design QR finder shape
Kwanghoon Son [Fri, 3 Feb 2023 02:33:35 +0000 (11:33 +0900)]
Add design QR finder shape

Change-Id: I9641480cbc213cc9862694d9c57614445a8d7a51
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
15 months agoAdd Design QR header and test
Kwanghoon Son [Thu, 2 Feb 2023 07:09:36 +0000 (16:09 +0900)]
Add Design QR header and test

Design QR is for supporting various shape of finder and anchor pattern.
This patch include
1. MV_BARCODE_GENERATE_ATTR_{DATA,FINDER}_SHAPE
2. header value of mv_barcode_generate_attr_shape_e
3. chain engineCfg parameter to createBarcode function because so many
parameters will increase without engineCfg

Change-Id: Ib931c15e97bbb8439f564fb1826bfa9ca38ebc8e
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
15 months agomv_machine_learning: introduce image classification task group
Inki Dae [Wed, 8 Feb 2023 04:46:51 +0000 (13:46 +0900)]
mv_machine_learning: introduce image classification task group

[Issue type] : new feature

Introduce itask based image classification task group which is just a portion
of code refactoring to the legacy deep learning API set.

As we had a talk internally, I will introduce each task group based on
itask interface which is able to inference existing all image classification
models, and we will deprecate all legacy code as soon as all
task groups are introduced. Until that, we will use "internal" postfix
for all the CAPI.

Below is the new CAPI set,
  mv_image_classification_create
  mv_image_classification_destroy
  mv_image_classification_configure
  mv_image_classification_prepare
  mv_image_classification_inference
  mv_image_classification_get_label
  mv_image_classification_set_model

And its test case application,
test_image_classification

Change-Id: I846fd1685b1185d0cd60409aa45bbb04a9f17ca6
Signed-off-by: Inki Dae <inki.dae@samsung.com>
15 months agoFix format
Kwanghoon Son [Fri, 10 Feb 2023 02:59:41 +0000 (11:59 +0900)]
Fix format

Change-Id: Ice108ec97ca9af1faaef22f3047f2e4cf4f77e99
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
15 months agomv_machine_learning: drop backbone model code dependency
Inki Dae [Thu, 19 Jan 2023 01:25:49 +0000 (10:25 +0900)]
mv_machine_learning: drop backbone model code dependency

[Issue type] code refactoring

Did code refactoring by dropping backbone model code dependency.

With this patch, we can change facenet to other without code modification.
Only what we have to do for the use of new backbone model is to update
each "value" attribute of two types of face_recognition.json file,
    "name"  : "FACE_RECOGNITION_INPUT_TENSOR_SHAPE",
    "type" : "array",
    "subtype" : "integer",
    "value" : [ 512, 1 ] <- input tensor shape of training model which is same
                            as output tensor shape of backbone model.

    "name"  : "FACENET_OUTPUT_TENSOR_NAME",
    "type"  : "string",
    "value" : "normalize/l2_normalize" <- output tensor name of backbone model.

Change-Id: I9e32c73e029d67a1c86e8b2c7b424cb09d614463
Signed-off-by: Inki Dae <inki.dae@samsung.com>
15 months agomv_machine_learning: drop deprecated enum type
Inki Dae [Mon, 16 Jan 2023 07:46:39 +0000 (16:46 +0900)]
mv_machine_learning: drop deprecated enum type

[Issue type] code cleanup

Dropped the deprecated target type enum type and relevant code.

This is a old type which indicates a type on inference target device
but new type is used instead. So drop it to reduce code complexity.
We don't have to consider the old type anymore.

Change-Id: I68b59a334e274af740201c09b8e7f80ce524510a
Signed-off-by: Inki Dae <inki.dae@samsung.com>
15 months agoSupport new DFS_DATA_INPUT_FORMAT_COUPLED_TB
Tae-Young Chung [Mon, 19 Dec 2022 05:21:22 +0000 (14:21 +0900)]
Support new DFS_DATA_INPUT_FORMAT_COUPLED_TB

[Issue type] new feature

This commit is to support new feature
https://review.tizen.org/gerrit/#/c/platform/core/multimedia/dfs-adaptation/+/285723/

Change-Id: Iaeb2faa55cbdebac5bfef5272fbfa132384356f1
Signed-off-by: Tae-Young Chung <ty83.chung@samsung.com>
15 months agomv_barcode: clean duplicate code
Kwanghoon Son [Fri, 6 Jan 2023 10:15:40 +0000 (19:15 +0900)]
mv_barcode: clean duplicate code

mv_barcode_generate_{source,image}_open share duplicate code

Change-Id: Icf22352e4225de141d54c1a677f52dff958cbc23
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
15 months agotest: correct object detection test image patch 27/287927/3
Inki Dae [Wed, 8 Feb 2023 01:46:58 +0000 (10:46 +0900)]
test: correct object detection test image patch

Change-Id: If3bab3f36aaa790871079a1620097364e46e2fd8
Signed-off-by: Inki Dae <inki.dae@samsung.com>
15 months agomv_machine_learning: correct tensor buffer size 26/287926/3
Inki Dae [Wed, 8 Feb 2023 01:25:26 +0000 (10:25 +0900)]
mv_machine_learning: correct tensor buffer size

[Version] : 0.26.7
[Issue type] : bug fix

Correct output tensor buffer size.

In original code, we set the size of inference_engine_tensor_buffer to
the one of inference_engine_tensor_info, and this incurs seg. fault
in case of not using float data type. These sizes are different each other
like below,

Size of inference_engine_tensor_info : tensor element count
Size of inference_engine_tensor_buffer : tensor element count * bytes per
an element.

So this patch calculates the size of inference_engine_tensor_buffer correctly
by checking actual bytes per an tensor element.

Change-Id: I21733fb341e93f325f6d4a3bb4df66ff69e15413
Signed-off-by: Inki Dae <inki.dae@samsung.com>
15 months agomv_machine_learning: bug fix to tensor buffer allocation 35/287835/1
Inki Dae [Tue, 7 Feb 2023 04:24:05 +0000 (13:24 +0900)]
mv_machine_learning: bug fix to tensor buffer allocation

[Version] : 0.26.6
[Issue type] : bug fix

Fixed a bug to wrong tensor buffer allocation since commit-id
ee852016683c6fed53fdddcc54ebea2c9212e4ff

For the output tensor, we have to allocate the output tensor buffer
not input tensor one.

Change-Id: I0653e7726666ae122e42e52d6ced8874d2b1ac3c
Signed-off-by: Inki Dae <inki.dae@samsung.com>
16 months agomerge tizen_devel to tizen accepted/tizen/unified/20230113.091231
Inki Dae [Tue, 10 Jan 2023 08:56:03 +0000 (17:56 +0900)]
merge tizen_devel to tizen

Inki Dae (5):
  mv_machine_learning: code refactoring to face recognition
  mv_machine_learning: face recognition: consider multiple threads
  mv_machine_learning: face recognition: allow 5 set per a label
  mv_machine_learning: tc: fix bugs
  mv_machine_learning: face recognition: drop nntrainer dependency

Kwanghoon Son (4):
  Fix json_to_string memory leak
  Fix LOGE to LOGI
  Fix QRcode error handle
  Delete null check before free

 mv_3d/3d/src/mv_3d_open.cpp                   |  12 +-
 .../src/mv_barcode_generate_open.cpp          |   8 +-
 mv_machine_learning/common/include/context.h  |   4 +-
 .../face_recognition/CMakeLists.txt           |   2 +-
 .../include/face_recognition.h                |  45 ++--
 .../include/face_recognition_adapter.h        |  35 +--
 ...nntrainer_dsm.h => face_recognition_dsm.h} |  11 +-
 ...nntrainer_fvm.h => face_recognition_fvm.h} |  11 +-
 .../include/face_recognition_type.h           |  82 +++++++
 .../face_recognition/include/facenet.h        |  64 ++++++
 .../include/facenet_adapter.h                 |  52 +++++
 .../{face_net_info.h => facenet_parser.h}     |  31 +--
 .../face_recognition/include/simple_shot.h    |   4 +-
 .../meta/face_recognition.json                |  26 ++-
 .../face_recognition/src/face_net_info.cpp    |  61 ------
 .../face_recognition/src/face_recognition.cpp | 204 ++++--------------
 .../src/face_recognition_adapter.cpp          |  37 ++--
 ...ainer_dsm.cpp => face_recognition_dsm.cpp} |  21 +-
 ...ainer_fvm.cpp => face_recognition_fvm.cpp} |  27 +--
 .../face_recognition/src/facenet.cpp          | 147 +++++++++++++
 .../face_recognition/src/facenet_adapter.cpp  |  71 ++++++
 .../face_recognition/src/facenet_parser.cpp   |  49 +++++
 .../src/mv_face_recognition_open.cpp          | 106 ++++++---
 .../face_recognition/src/simple_shot.cpp      |  19 +-
 .../inference/include/Inference.h             |  12 +-
 .../inference/src/Inference.cpp               |  22 +-
 .../inference/src/InputMetadata.cpp           |   8 +-
 .../inference/src/OutputMetadata.cpp          |   4 +-
 .../inference/src/mv_inference_open.cpp       |  18 +-
 mv_machine_learning/meta/src/MetaParser.cpp   |   8 +-
 .../training/include/data_set_manager.h       |   3 +
 .../training/include/feature_vector_manager.h |   5 +-
 .../training/include/training_model.h         |   6 +-
 .../training/src/data_set_manager.cpp         |   1 +
 .../training/src/training_model.cpp           |   7 +-
 .../surveillance/src/EventTrigger.cpp         |   8 +-
 .../src/EventTriggerPersonRecognition.cpp     |  24 +--
 .../surveillance/src/mv_surveillance.c        |   6 +-
 packaging/capi-media-vision.spec              |   1 +
 test/CMakeLists.txt                           |   4 +-
 .../surveillance/assessment_surveillance.cpp  |  12 +-
 test/testsuites/barcode/barcode_test_suite.c  |  40 ++--
 test/testsuites/barcode/test_barcode.cpp      |  52 ++++-
 .../visualizer/src/mv_util_render_2d.cpp      |   3 +-
 .../face_recognition/CMakeLists.txt           |   9 +-
 .../test_face_recognition.cpp                 |  23 +-
 .../test_face_recognition_multi_threads.cpp   | 196 +++++++++++++++++
 47 files changed, 1067 insertions(+), 534 deletions(-)
 rename mv_machine_learning/face_recognition/include/{nntrainer_dsm.h => face_recognition_dsm.h} (80%)
 rename mv_machine_learning/face_recognition/include/{nntrainer_fvm.h => face_recognition_fvm.h} (78%)
 create mode 100644 mv_machine_learning/face_recognition/include/face_recognition_type.h
 create mode 100644 mv_machine_learning/face_recognition/include/facenet.h
 create mode 100644 mv_machine_learning/face_recognition/include/facenet_adapter.h
 rename mv_machine_learning/face_recognition/include/{face_net_info.h => facenet_parser.h} (56%)
 delete mode 100644 mv_machine_learning/face_recognition/src/face_net_info.cpp
 rename mv_machine_learning/face_recognition/src/{nntrainer_dsm.cpp => face_recognition_dsm.cpp} (83%)
 rename mv_machine_learning/face_recognition/src/{nntrainer_fvm.cpp => face_recognition_fvm.cpp} (64%)
 create mode 100644 mv_machine_learning/face_recognition/src/facenet.cpp
 create mode 100644 mv_machine_learning/face_recognition/src/facenet_adapter.cpp
 create mode 100644 mv_machine_learning/face_recognition/src/facenet_parser.cpp
 create mode 100644 test/testsuites/machine_learning/face_recognition/test_face_recognition_multi_threads.cpp

Change-Id: I5e2748553886ab196412b0420f83d686ea5731c0
Signed-off-by: Inki Dae <inki.dae@samsung.com>
16 months agomv_machine_learning: face recognition: drop nntrainer dependency 68/286368/3
Inki Dae [Thu, 5 Jan 2023 00:37:18 +0000 (09:37 +0900)]
mv_machine_learning: face recognition: drop nntrainer dependency

[Issue type] code refactoring

Did code refactoring to face recognition by dropping NNTrainer dependency.
With this patch, Face recognition framework uses only NNTrainer backend
type for inference and training. And also did code cleanup by
dropping redundant code.

Change-Id: Idb1ec527f9f08b5f18a6c647325a99092d0ed4ff
Signed-off-by: Inki Dae <inki.dae@samsung.com>
16 months agomv_machine_learning: tc: fix bugs 05/286305/2
Inki Dae [Tue, 3 Jan 2023 10:02:09 +0000 (19:02 +0900)]
mv_machine_learning: tc: fix bugs

[Issue type] : Bug fix

Fixed two bugs,
  - fix a issue that mv source can be destroyed in duplucation.
  - fix a issue that mv_face_recognition_prepare function is called
    several times.

Change-Id: I432b9ce3f0fa1432054b3f3c2f8e0caeb5a60316
Signed-off-by: Inki Dae <inki.dae@samsung.com>
16 months agomv_machine_learning: face recognition: allow 5 set per a label 04/286304/2
Inki Dae [Tue, 3 Jan 2023 09:43:01 +0000 (18:43 +0900)]
mv_machine_learning: face recognition: allow 5 set per a label

[Issue type] New feature

Added a new feature that it allows maximum 5 set of feature vector
per a label. In case of few-shot leanring based on KNN algorthm,
Feature vector set more than 5 aren't needed.

This is a temporary solution so I will introduce a feature vector priority
based solution if NNTrainer is ready for this later.

Change-Id: I57d24f36101b354ea2e0fed8134f99a31e32307e
Signed-off-by: Inki Dae <inki.dae@samsung.com>
16 months agoMerge "mv_machine_learning: face recognition: consider multiple threads" into tizen_devel
Inki Dae [Tue, 3 Jan 2023 06:27:57 +0000 (06:27 +0000)]
Merge "mv_machine_learning: face recognition: consider multiple threads" into tizen_devel

16 months agomv_machine_learning: face recognition: consider multiple threads 20/286220/4
Inki Dae [Fri, 30 Dec 2022 02:21:50 +0000 (11:21 +0900)]
mv_machine_learning: face recognition: consider multiple threads

[Issue type] : new feature

Considered multiple threads to face recognigion task API.

In application, it can request an inference and register even unregister
by each thread context. So make sure to guarantee such requests using mutex.

And also this patch introduces test_face_recognition_multi_threads app
which adds two test cases, InferenceAndRegisterShouldBeOk
and InferenceAndRegisterAndUnregisterShouldBeOk, to test multiple threads.

Change-Id: I9217a572f6746591eeda774f113e9f2b23c82a8a
Signed-off-by: Inki Dae <inki.dae@samsung.com>
16 months agoMerge "Delete null check before free" into tizen_devel
kwang son [Tue, 3 Jan 2023 02:23:22 +0000 (02:23 +0000)]
Merge "Delete null check before free" into tizen_devel

16 months agoMerge "Fix QRcode error handle" into tizen_devel
kwang son [Tue, 3 Jan 2023 02:18:31 +0000 (02:18 +0000)]
Merge "Fix QRcode error handle" into tizen_devel

17 months agoDelete null check before free 62/286162/1
Kwanghoon Son [Thu, 29 Dec 2022 08:58:25 +0000 (17:58 +0900)]
Delete null check before free

C standards 7.20.3.2/2 from ISO-IEC 9899 note free check null, so it's all dummy code.

Change-Id: Iec43e9040ce7d26c6ee45d388e66cf3f8f670b0e
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
17 months agomv_machine_learning: code refactoring to face recognition 71/285971/7
Inki Dae [Mon, 12 Dec 2022 09:37:29 +0000 (18:37 +0900)]
mv_machine_learning: code refactoring to face recognition

[Issue type] : code refactoring

Did code refactoring by doing,
- Rework facenet inference using itask. With this change,
  facenet inference is handled by face recognition task API
  implementation. And this is a main purpose of this patch.
- Update meta file for face recognition task by adding several
  meta parameters.
- and code cleanup.

This is a step for introducing new feature vector manager.

Change-Id: Ia38c4dc9c45b3216d88acf5f80befd2c02da2aad
Signed-off-by: Inki Dae <inki.dae@samsung.com>
17 months agoFix QRcode error handle 15/286115/5
Kwanghoon Son [Wed, 28 Dec 2022 06:52:38 +0000 (15:52 +0900)]
Fix QRcode error handle

Change default error MEDIA_VISION_ERROR_NONE to
MEDIA_VISION_ERROR_INTERNAL.

[Issue type] Fix

Change-Id: I61bfa695f98341b979be5d91646831763b9f6298
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
17 months agoFix LOGE to LOGI 96/286096/1
Kwanghoon Son [Wed, 28 Dec 2022 01:57:18 +0000 (10:57 +0900)]
Fix LOGE to LOGI

[Issue type] Fix

Change-Id: I7828d3dc85a64e6879371b2385fa9afcf2e931cb
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
17 months agoFix json_to_string memory leak 71/285871/2
Kwanghoon Son [Thu, 22 Dec 2022 03:35:13 +0000 (12:35 +0900)]
Fix json_to_string memory leak

[Issue type] Bug fix

Change-Id: Ia0785b256f9323f8388c22cb7f2526f220b3cf3a
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
17 months agoMerge branch 'tizen_devel' into tizen
Kwanghoon Son [Wed, 14 Dec 2022 06:33:45 +0000 (15:33 +0900)]
Merge branch 'tizen_devel' into tizen

Inki Dae (2):
  mv_machine_leanring: code refactoring to face recognition
  mv_machine_learning: fix build error

Kwanghoon Son (4):
  Add yolo5s model on SNPE
  Change rpm name testsuite to unittests
  setup and teardown for line coverage
  Force clang-format to version 9

Seungbae Shin (3):
  mv3d: pass raw pointer to g_async_queue instead to make code simple
  mv3d: keep pointcloud as a shared_ptr form instead of raw void*
  Fix build warnings

Tae-Young Chung (4):
  mv3d: get the latest in mDfsAsyncQueue
  Update parts of getting the latest in mDfsAsyncQueue
  mv3d: fix vision.3d feature check
  mv3d: create DfsAdaptor and call bind() when mDfsAdaptor is nullptr

Change-Id: I357659abe8f57d8777b1c780bb463f8f6f62e7bf

17 months agoFix build warnings
Seungbae Shin [Thu, 8 Dec 2022 11:16:56 +0000 (20:16 +0900)]
Fix build warnings

[Issue type] : build
[Version] 0.26.4

Change-Id: Ie7b0eb67be7f298e76225d93a2217d5e53fcc5b6

17 months agomv3d: keep pointcloud as a shared_ptr form instead of raw void*
Seungbae Shin [Fri, 23 Sep 2022 05:37:53 +0000 (14:37 +0900)]
mv3d: keep pointcloud as a shared_ptr form instead of raw void*

The shared_ptr is exactly what we got from geometry::PointCloud::CreateFrom RGBDImage(),
eventually, this change gives us better readability and safety.

[Issue type] refactoring
[Version] 0.26.3

Change-Id: I20e4f95e272dbd8a05ce18c267c1dc84539387d0

17 months agomv3d: pass raw pointer to g_async_queue instead to make code simple
Seungbae Shin [Thu, 22 Sep 2022 11:58:24 +0000 (20:58 +0900)]
mv3d: pass raw pointer to g_async_queue instead to make code simple

[Issue type] refactoring
[Version] 0.26.2

In addition, make g_async_queue to cleanup automatically for the remained items.

Change-Id: Ibab33c79bd520d2d8acbdfdebca07628c8b2edc7

17 months agoForce clang-format to version 9
Kwanghoon Son [Wed, 14 Dec 2022 00:13:31 +0000 (09:13 +0900)]
Force clang-format to version 9

[Issue type] lint

Output from clang-format varies by clang-format version, for the best
result we force it to version 9.
Could run with ./script/excute_format.sh for all formatting. Also
jenkins bot will test it.

Change-Id: Id9e2ef4e9d74cf0e518f0a04efd1c49e4502b97c
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
17 months agomv3d: create DfsAdaptor and call bind() when mDfsAdaptor is nullptr
Tae-Young Chung [Tue, 6 Dec 2022 04:59:44 +0000 (13:59 +0900)]
mv3d: create DfsAdaptor and call bind() when mDfsAdaptor is nullptr

[Issue type] bug fix

Change-Id: Id0642bb9f17b3be2522b6cacad8a5feb5750a5fb
Signed-off-by: Tae-Young Chung <ty83.chung@samsung.com>
17 months agomv3d: fix vision.3d feature check
Tae-Young Chung [Tue, 6 Dec 2022 03:34:05 +0000 (12:34 +0900)]
mv3d: fix vision.3d feature check

[Issue type] bug fix

Change-Id: I9022dcecaf812bc866ee36ee7cff758fb413f7c9
Signed-off-by: Tae-Young Chung <ty83.chung@samsung.com>
17 months agomv_machine_learning: fix build error
Inki Dae [Tue, 6 Dec 2022 05:03:29 +0000 (14:03 +0900)]
mv_machine_learning: fix build error

[Issue type] : bug fix

Fixed a build error due to using not supported interface - GetWeightWithLayer
- of training engine interface by dropping the relevant code.

This code will be revisited after updating training engine interface later.

Change-Id: Id50415de47022b189933477cd69495639907690a
Signed-off-by: Inki Dae <inki.dae@samsung.com>
17 months agomv_machine_leanring: code refactoring to face recognition
Inki Dae [Wed, 30 Nov 2022 01:22:18 +0000 (10:22 +0900)]
mv_machine_leanring: code refactoring to face recognition

[Issue type] : code refactoring

Did code refactoring to face recognition framework by doing,
- Change feature vector file format to reduce unnecessary iteration
  overhead.
  [before]
  |feature vector|one-hot-encoding-table|...|header|
  [after]
  [feature vector|label index|...|header|
- Store data set to feature vector file after training because
  we need to consider feature vector priority based data set
  management policy later - this patch is just a step for it.
- Several code cleanups.

On top of this patch, I will add the new data set management policy.

Change-Id: Ibaa866533a2f3187c353f6fb543821bb79ddfa98
Signed-off-by: Inki Dae <inki.dae@samsung.com>
17 months agosetup and teardown for line coverage
Kwanghoon Son [Wed, 23 Nov 2022 03:03:13 +0000 (22:03 -0500)]
setup and teardown for line coverage

[Issue type] New
[Version] 0.26.1

Script will install resources for test and delete.

Change-Id: Ica9b7f0c9522863b3cc04f558b24c21dda0fbcae
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
17 months agoUpdate parts of getting the latest in mDfsAsyncQueue
Tae-Young Chung [Mon, 28 Nov 2022 07:06:18 +0000 (16:06 +0900)]
Update parts of getting the latest in mDfsAsyncQueue

Change-Id: Ica5b2236ca869f9a415143f1737fbced9321157e
Signed-off-by: Tae-Young Chung <ty83.chung@samsung.com>
17 months agoChange rpm name testsuite to unittests
Kwanghoon Son [Tue, 22 Nov 2022 01:37:18 +0000 (20:37 -0500)]
Change rpm name testsuite to unittests

[Issue type] New
[Version] 0.26.0

For auto linecoverage, this require explicit package name and script to
run.

Change-Id: I2610021585e4ae1f337cb7f810be31a00dcc24c2
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
17 months agomv3d: get the latest in mDfsAsyncQueue
Tae-Young Chung [Mon, 14 Nov 2022 06:44:16 +0000 (15:44 +0900)]
mv3d: get the latest in mDfsAsyncQueue

[Issue type] update

Change-Id: I5c38a52b2bdfe439e01d1027ca30742a7486c34f
Signed-off-by: Tae-Young Chung <ty83.chung@samsung.com>
17 months agoAdd yolo5s model on SNPE
Kwanghoon Son [Fri, 18 Nov 2022 05:48:56 +0000 (00:48 -0500)]
Add yolo5s model on SNPE

[Issue type] new

Change-Id: If3209125970b1e8e2cce9cda9000f89c6617ce2b
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
17 months agocall glClear before rendering 3D 28/285528/2
sangho park [Wed, 14 Dec 2022 05:22:19 +0000 (14:22 +0900)]
call glClear before rendering 3D

[Version] 0.25.4
[Issue type] bug fix

Change-Id: Ice1483919e7c8cd886736217e787addedeb59a4b
Signed-off-by: sangho park <sangho.g.park@samsung.com>
17 months agoChange GL_RGB to GL_RGBA for rendering 2D visualizer 50/285350/1
sangho park [Fri, 9 Dec 2022 08:57:12 +0000 (17:57 +0900)]
Change GL_RGB to GL_RGBA for rendering 2D visualizer

[Version] 0.25.3
[Issue type] bug fix

Change-Id: I4ec4482056dcdd74a6e7972de8a2515e87f978d0
Signed-off-by: sangho park <sangho.g.park@samsung.com>
18 months agoApply clang-format
Kwanghoon Son [Thu, 17 Nov 2022 07:34:00 +0000 (02:34 -0500)]
Apply clang-format

[Issue type] refactoring
[Version] 0.25.2

Change-Id: Ib9ef6823873bc452ac48257615fc6e61977f4247
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
18 months agoMerge branch 'tizen_devel' into tizen 43/284443/1
Kwanghoon Son [Thu, 17 Nov 2022 06:57:44 +0000 (01:57 -0500)]
Merge branch 'tizen_devel' into tizen

[Issue type] sync
[Version] 0.25.1

Inki Dae (2):
  mv_machine_learning: add new meta file approach
  mv_machine_learning: add postprocess support

Kwanghoon Son (2):
  Fix nested condition and formatting
  Add postprocess for letterbox

Tae-Young Chung (1):
  Change default value of MV_3D_DEPTH_MODE in json to '1', and add error
    return when the mode is MV_3D_DEPTH_MODE_NONE

Change-Id: I22a3ca06b5f2ad6101977a5d37351aec21cf9d1f

18 months agomv_machine_learning: add postprocess support 87/284287/7
Inki Dae [Wed, 9 Nov 2022 08:56:20 +0000 (17:56 +0900)]
mv_machine_learning: add postprocess support

[Issue type] new feature

Added postprocess support for objectron model of object detection Task
API group.

What this code refactoring does,
 - implement postprocess design for the new meta file approach.
 - add postprocess support to objectron model using this new design.

Change-Id: Ibcf0d9bfffd5dc411ff6b9f44107823021c7cfa6
Signed-off-by: Inki Dae <inki.dae@samsung.com>
18 months agoMerge "Add postprocess for letterbox" into tizen_devel
kwang son [Thu, 17 Nov 2022 01:47:38 +0000 (01:47 +0000)]
Merge "Add postprocess for letterbox" into tizen_devel

18 months agoFix tizen coding rule M16 30/284330/1
Kwanghoon Son [Wed, 16 Nov 2022 01:07:07 +0000 (20:07 -0500)]
Fix tizen coding rule M16

[Issue type] Fix

[M16] Open braces for enum, union and struct go on the same line.

this make braces to
```
struct people { // same line
};
```

Change-Id: I4c2c293244c8bbfaf6630ccda861f1e96cf0c153
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
18 months agoChange default value of MV_3D_DEPTH_MODE in json to '1', 25/284225/2
Tae-Young Chung [Mon, 14 Nov 2022 02:58:20 +0000 (11:58 +0900)]
Change default value of MV_3D_DEPTH_MODE in json to '1',
and add error return when the mode is MV_3D_DEPTH_MODE_NONE

[Issue type] update and bug fix

Change-Id: I23d73be70123c07ae7d2bd931207e9f4e90ff5b3
Signed-off-by: Tae-Young Chung <ty83.chung@samsung.com>
18 months agoAdd postprocess for letterbox 46/284246/2
Kwanghoon Son [Mon, 14 Nov 2022 07:25:40 +0000 (02:25 -0500)]
Add postprocess for letterbox

Letterbox needs postprocessing for object result location.
Also fix some code indent

[Issue type] New

Change-Id: Ief7720f7a2260277e96aba5dc66a58c78e475794
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
18 months agoMerge "Fix nested condition and formatting" into tizen_devel
kwang son [Mon, 14 Nov 2022 04:17:10 +0000 (04:17 +0000)]
Merge "Fix nested condition and formatting" into tizen_devel

18 months agomv_machine_learning: add new meta file approach 83/283983/9
Inki Dae [Tue, 1 Nov 2022 01:42:54 +0000 (10:42 +0900)]
mv_machine_learning: add new meta file approach

[Version] : 0.25.0-0
[Issue type] : new feature

Add a new meta file approach.

The purpose of this new approach is to drop the Inference class dependency
from existing meta file approach, and instead to move the dependency to
each task framework so that Inference class can focus on only inference
work. As a initial work, this new approach is applied to object detection
3d task framework first, and then later for other task frameworks.

With this new approach, meta file is managed like below,
- Each model has two meta objects, one is for input and other is for output.
- Each meta object has its own decoding_info object which includes
  decoding_info objects for preprocess or postprocess according to
  a given meta object - input meta or output meta object.
- Introduce MetaParser class which is a base class to parse tensor
  and preprocess information from a given meta file, and its derived class
  to each task framework, which parses only postprocess node.
  MetaParser class is used commonly for all task frameworks, and
  each task framework has to implement the derivied class which has
  only one virtual function to parse postprocess node specific to each
  task framework.

On top of this patch, I will do code refactoring to other task frameworks.
And finally, existing old one will be dropped after the completion of the code
refactoring.

Change-Id: I0932024d16bf3275f8f1d25449a461f4fe362265
Signed-off-by: Inki Dae <inki.dae@samsung.com>
18 months agoFix nested condition and formatting 57/283957/2
Kwanghoon Son [Tue, 8 Nov 2022 01:05:24 +0000 (20:05 -0500)]
Fix nested condition and formatting

[Issue type] refactoring

Change-Id: I59b02a9b61d993dce502cda7f482fa30cfc9ce63
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
18 months agoMerge branch 'tizen_devel' into tizen
Tae-Young Chung [Wed, 9 Nov 2022 01:44:35 +0000 (10:44 +0900)]
Merge branch 'tizen_devel' into tizen

[Version] 0.24.3-0
[Issue type] sync branch

Merge history
```
Tae-Young Chung (1):
  Add remote display to depthstream_test_suite

 .../mv3d/depthstream_test_suite.cpp           | 154 ++++++++++++++----
 1 file changed, 119 insertions(+), 35 deletions(-)
```

Change-Id: I5fbfa6c25f0e1d7169f23e810b4e62c8a329fca2

18 months agoAdd remote display to depthstream_test_suite 21/283921/9
Tae-Young Chung [Mon, 7 Nov 2022 07:56:22 +0000 (16:56 +0900)]
Add remote display to depthstream_test_suite

[Issue type] update

Change-Id: I06add78361bcb62f1e4930a5414bc2acd4784d32
Signed-off-by: Tae-Young Chung <ty83.chung@samsung.com>
18 months agoMerge branch 'tizen_devel' into tizen
Kwanghoon Son [Tue, 8 Nov 2022 02:19:01 +0000 (21:19 -0500)]
Merge branch 'tizen_devel' into tizen

Resolve Conflicts with version assign and up to 0.24.2

Change-Id: I2188aba89c710175b2b5b3ee5d525d771911a212
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
18 months agoVersion up to 0.24.2
Kwanghoon Son [Tue, 8 Nov 2022 02:16:57 +0000 (21:16 -0500)]
Version up to 0.24.2

Change-Id: I0f1b2a200f144be1aac819207d71cc233e380f1b
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
18 months agoVersion up to 0.24.1
Kwanghoon Son [Tue, 8 Nov 2022 02:15:16 +0000 (21:15 -0500)]
Version up to 0.24.1

Change-Id: I7077d820d57e8a0ab30b694f1448c00870ca9855
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
18 months agoFix Yolo {x,y}_scales parser 17/283917/3
Kwanghoon Son [Mon, 7 Nov 2022 07:37:21 +0000 (02:37 -0500)]
Fix Yolo {x,y}_scales parser

[Issue type] bug fix

Previous yolo json use nested {x,y}_scales member in multiple names.
But this changed to multiple output layer with each names.

As-is
"name" : ["378", "398", ...],
"x_scales" :
[
    [1.25000, 2.00000, 4.12500],
    [1.87500, 3.87500, 3.68750],
    [3.62500, 4.87500, 11.65625]
],

To-be
[{ "name": "378",
...
"x_scales": [ 1.25000, 2.00000, 4.12500 ],},
{ "name": "398",
...
"x_scales": [1.87500, 3.87500, 3.68750],},
...
]

Change-Id: I3e8f4abd96edf101d7faabcf3b409b2b69b7019e
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
18 months agoAdd remote display to depth_test_suite 16/283916/1
Tae-Young Chung [Mon, 7 Nov 2022 06:47:18 +0000 (15:47 +0900)]
Add remote display to depth_test_suite

[Issue type] update

Change-Id: I25be56bb0ed0c43e6f4d6c4d25427d646c84eb2d
Signed-off-by: Tae-Young Chung <ty83.chung@samsung.com>
18 months agoChange server and visualizer_test_suite to get url as an input 07/283907/2
Tae-Young Chung [Mon, 7 Nov 2022 05:57:37 +0000 (14:57 +0900)]
Change server and visualizer_test_suite to get url as an input

[Issue type] update

Change-Id: I6728021226ff9fd2b74ec7f656ab04c1ea25031e
Signed-off-by: Tae-Young Chung <ty83.chung@samsung.com>
18 months agoAdd letter box
Kwanghoon Son [Wed, 2 Nov 2022 10:57:39 +0000 (06:57 -0400)]
Add letter box

[Issue type] New feature

SNP yolo model needs letterbox preprocessing.
Define resize method and parser.

Change-Id: I1a02f5a1823aa3d017cd8ba33dfcfa5558d9a592
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
18 months agoChange InputMetadata class to struct
Kwanghoon Son [Wed, 2 Nov 2022 01:19:15 +0000 (21:19 -0400)]
Change InputMetadata class to struct

[Issue type] refactoring

Metadata just hold informations. To prevent make all get/setter method,
change class to struct same as OutputMetadata.

Change-Id: Ib9a8246d2be26d2fe0a2d33e66abf880d75f0761
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
18 months agomv_machine_learning: code refactoring to meta file approach
Inki Dae [Mon, 17 Oct 2022 09:00:46 +0000 (18:00 +0900)]
mv_machine_learning: code refactoring to meta file approach

[Issue type] code refactoring

Did code refactoring to meta file approach by doing,
- Change existing meta file format with more generic way.
  With this change, we can describe all input and output tensors of models.
  Existing meta file didn't describe output tensor information but only
  decoding way, and it made the use of multiple tensor descriptions
  with their pre/post process ways not possible because tensor and
  pre/post process information was handled separetely.
  So we don't need to thinking of them separetely because each tensor
  can or can't include pre/post process task according to a given model
  file and even there are many combinations of them.
- Introduce MetadataType.h header file which includes meta file approach
  common types.
    - Introduce LabelInfo.h/cpp, NumberInfo.h/cpp.

The main purpose of this refactoring applies the enhanced meta file format,

Before
======

{
"inputmetadata" :
{
"tensor_info" : [
{
"name" : "xxx",
...
}
]
"preprocess" : [
{
"normalization" : [
{
...
}
]
...
}
]
}
"outputmetadata" :
{
"box" :
{
"name" : "tensor1_name",
..
},
"score" :
{
"name" : "tensor2_name",
},
...
}
}

[After]
=======

{
"input" : [
{
"tensor1" : {
"name" : "xxx",
...
"preprocess" : {
"normalization" : {
...
}
}
}
...
}
]

"output" : [
{
"tensor1" : {
"name" : "tensor1_name",
...
"postprocess" : {
"box" : {
...
}
}
},
"tensor2" : {
"name" : "tensor2_name",
...
"postprocess" : {
"score" : {
...
}
}
}
...
}
]
}

Change-Id: I9d9be615dc3dd972d506b807030c745d8a0916a9
Signed-off-by: Inki Dae <inki.dae@samsung.com>
18 months agofixup! mv_machine_learning: keep object detection 3d as internal api
Seungbae Shin [Thu, 6 Oct 2022 03:08:34 +0000 (12:08 +0900)]
fixup! mv_machine_learning: keep object detection 3d as internal api

Change-Id: I9e06f1c0d98d74b147e97bf6fb5a27abccc19bc9

18 months agomv_machine_learning: keep object detection 3d as internal api
Inki Dae [Thu, 6 Oct 2022 01:24:30 +0000 (10:24 +0900)]
mv_machine_learning: keep object detection 3d as internal api

[Issue type] code cleanup

Keep object detection 3d API as internal one. This API will be announced
officially next year with several enhancements.

Change-Id: Ia775569a3572a9fff75780fcdffa2a183dbf1885
Signed-off-by: Inki Dae <inki.dae@samsung.com>
18 months agomv_machine_learning: use reference and vector
Inki Dae [Mon, 26 Sep 2022 07:56:43 +0000 (16:56 +0900)]
mv_machine_learning: use reference and vector

[Issue type] : code clean

Use reference instead of pointer when returning the result to user
and replace the array type of members of object_detection_3d_result_s structure
with vector type.

Change-Id: Ieed3a2d087e617af604f7a42d57d7a78eab0d116
Signed-off-by: Inki Dae <inki.dae@samsung.com>
18 months agomv_machine_learning: fix model path
Inki Dae [Wed, 21 Sep 2022 07:12:32 +0000 (16:12 +0900)]
mv_machine_learning: fix model path

[Issue type] : bug fix

Change-Id: Iafabaa2b51c7ec4d0c12f93ce485e75f87e876cc
Signed-off-by: Inki Dae <inki.dae@samsung.com>
18 months agomv_machine_learning: do not use fixed array
Inki Dae [Tue, 20 Sep 2022 09:01:39 +0000 (18:01 +0900)]
mv_machine_learning: do not use fixed array

[Issue type] : code cleanup

Did code cleanup to the use of result structure, object_detection_3d_result_s
by doing,
   - Get the maximum number of poinsts and edges from specific json file.
   - Clean up json key string.

Change-Id: I23200c80c8d019c7aa02a608d3b92556af1e1605
Signed-off-by: Inki Dae <inki.dae@samsung.com>
18 months agomv_machine_learning: do not expose structure to user
Inki Dae [Mon, 19 Sep 2022 13:19:35 +0000 (22:19 +0900)]
mv_machine_learning: do not expose structure to user

[Issue type] code cleanup

Do not allow for user to access structure type instead, introduce
each CAPI corresponding to each member of the structure.

Change-Id: Iac3e475ebb54b862c0b007b84f228154a10f1308
Signed-off-by: Inki Dae <inki.dae@samsung.com>
18 months agomv_machine_learning: code refactoring to tensor info
Inki Dae [Mon, 19 Sep 2022 03:14:26 +0000 (12:14 +0900)]
mv_machine_learning: code refactoring to tensor info

[Issue type] : code refactoring

Did code refactoring to tensor information configuration by
separating legacy configuration function and meta file way.

Until now, legacy functions - ConfigureInputInfo and ConfigureOutputInfo
- was needed to configure the input and output tensor information
regardless of the use of legacy way or meta file approach because two cases
was considered by these functions at once. So this patch separates the
two cases into each function.

Change-Id: I7936e20be80acc7feb140bbc507f50189d0558c7
Signed-off-by: Inki Dae <inki.dae@samsung.com>
18 months agomv_machine_learning: add object detection 3d API
Inki Dae [Mon, 19 Sep 2022 02:32:37 +0000 (11:32 +0900)]
mv_machine_learning: add object detection 3d API

[Version] : 0.24.0-0
[Issue type] : new feature

Add Objectron model based object detection 3d API.

What this patch does,
    - Implement Objectron model[1] based object detection 3d framework.
    - Add object_detection directory in mv_machine_learning, which
      incluses object detection relevant files.
    - Add create interface to itask class, which creates model specific class
      object.
    - Implement Object detection and its based Objectron class for
      object detection 3d inference.
    - Implement itask interface class based object detection adapter class.
    - Implement object detection 3d API.

[1] https://arxiv.org/abs/2003.03522

Change-Id: I3f4f9d53a305bd45d83cb330757bc6d5f83396b8
Signed-off-by: Inki Dae <inki.dae@samsung.com>
18 months agoAdd ITC compatible tests
Kwanghoon Son [Thu, 22 Sep 2022 06:33:27 +0000 (02:33 -0400)]
Add ITC compatible tests

[Issue type] New test

Change-Id: I5830f009c889453127562b5f411e8db98eb6c41c
Signed-off-by: Kwanghoon Son <k.son@samsung.com>
19 months agofix build error with tv profile 16/283716/1 accepted/tizen/unified/20221103.165815
Tae-Young Chung [Wed, 2 Nov 2022 06:18:21 +0000 (15:18 +0900)]
fix build error with tv profile

[Version]: 0.23.41-2
[Issue type]: bug fix

Change-Id: I9e0b30396c78aa11c5134e51529acd6736157f46
Signed-off-by: Tae-Young Chung <ty83.chung@samsung.com>
19 months agofix build error with aarch64 32/283532/1 accepted/tizen/unified/20221102.085158
Tae-Young Chung [Fri, 28 Oct 2022 06:21:03 +0000 (15:21 +0900)]
fix build error with aarch64

[Version]: 0.23.41-1
[Issue type]: bug fix

Build error message:
```
[   17s] CMake Error at test/CMakeLists.txt:17 (target_link_libraries):
[   17s]   Error evaluating generator expression:
[   17s]
[   17s]     $<TARGET_PROPERTY:Open3D::Open3D,TYPE>
[   17s]
[   17s]   Target "Open3D::Open3D" not found.
```
This commit resolves it.

Change-Id: I2b2d20367011316b12c7c8ed3117731845156941
Signed-off-by: Tae-Young Chung <ty83.chung@samsung.com>
19 months agoadd test_3d.cpp to mv_test 57/283257/1
Tae-Young Chung [Fri, 21 Oct 2022 04:31:40 +0000 (13:31 +0900)]
add test_3d.cpp to mv_test

[Version]: 0.23.41-0
[Issue type]: update

test_3d.cpp for testing mv3d is added to mv_test which line coverage is
measured by.

Change-Id: I08e86eda14717bc1978aca4cd282621cbe4fb9f0
Signed-off-by: Tae-Young Chung <ty83.chung@samsung.com>
19 months agomv3d: exclude open3d from tv profile 76/283176/1
Tae-Young Chung [Thu, 20 Oct 2022 00:54:14 +0000 (09:54 +0900)]
mv3d: exclude open3d from tv profile

[Version]: 0.23.40-1
[Issue type]: update

VD has build profile with aarch64 but there is no Open3D package now.
This commit moves BuildRequires of Open3D-devel package when %arch is
aarch64 but profile isn't tv

Change-Id: I5c1f43e3fe1473f0cdeb50a4e779d735cbe09d16
Signed-off-by: Tae-Young Chung <ty83.chung@samsung.com>
19 months agosurveillance: fix data type 47/283147/2
Hyunsoo Park [Wed, 19 Oct 2022 04:24:05 +0000 (13:24 +0900)]
surveillance: fix data type

[Version]: 0.23.40-0
[Issue type]: bug fix

Change-Id: I65266048729e5ceaa188657b8d7f9abc49fc1978
Signed-off-by: Hyunsoo Park <hance.park@samsung.com>
19 months agoroi_tracker: fix typo 89/283089/1
Hyunsoo Park [Tue, 18 Oct 2022 02:32:19 +0000 (11:32 +0900)]
roi_tracker: fix typo

[Version]: 0.23.39-0
[Issue type]: docs

Change-Id: Ib4ab81e4466cd3391eb9857cc4fc2ea017161e22
Signed-off-by: Hyunsoo Park <hance.park@samsung.com>
19 months agomv3d: update depthstream_test_suite to use vision-source 00/282900/3
Tae-Young Chung [Thu, 13 Oct 2022 06:17:47 +0000 (15:17 +0900)]
mv3d: update depthstream_test_suite to use vision-source

[Version]: 0.23.38-0
[Issue type]: update

To test with camera, replace gstreamer based codes with vision-source
internal api.
Note that vision-source is internal api and unavailable in TV so that
some test suites aren't built in TV profile.

Change-Id: Iefc285f0d19ed2c4f6dbe4fba70f6991f4244229
Signed-off-by: Tae-Young Chung <ty83.chung@samsung.com>
19 months agomv3d: update depth_test_suite.cpp to select disparity or depth 84/282884/2
Tae-Young Chung [Thu, 13 Oct 2022 02:40:56 +0000 (11:40 +0900)]
mv3d: update depth_test_suite.cpp to select disparity or depth

[Version]: 0.23.37-0
[Issue type]: update

Change-Id: If782905b32fb2057d1b1c42c3c4438639438dac4
Signed-off-by: Tae-Young Chung <ty83.chung@samsung.com>
19 months agomv3d: fix wrong parameters order 38/282738/1 accepted/tizen_7.0_unified_hotfix tizen_7.0_hotfix accepted/tizen/7.0/unified/hotfix/20221116.104736 accepted/tizen/unified/20221012.014917 tizen_7.0_m2_release
Tae-Young Chung [Tue, 11 Oct 2022 03:30:59 +0000 (12:30 +0900)]
mv3d: fix wrong parameters order

[Version]: 0.23.36-0
[Issue type]: fix bad bug

Change-Id: I0c7e2c12afac2df7561fac3a072800d7bdc9e006
Signed-off-by: Tae-Young Chung <ty83.chung@samsung.com>