platform/upstream/nnstreamer.git
6 years ago[Test] Add GstFailTest API
MyungJoo Ham [Thu, 14 Jun 2018 11:54:30 +0000 (20:54 +0900)]
[Test] Add GstFailTest API

For unit-testing, we need to execute failing cases, where graceful exit is required.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Readme] update how-to-test guide
MyungJoo Ham [Fri, 15 Jun 2018 01:36:45 +0000 (10:36 +0900)]
[Readme] update how-to-test guide

We not have a central testing service at /tests/. Update README accordingly.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[CI] Add template for Issue & PR
Geunsik Lim [Fri, 15 Jun 2018 01:22:08 +0000 (10:22 +0900)]
[CI] Add template for Issue & PR

This PR is to create a template to automate issue and PR process.
It is cloned from https://github.sec.samsung.net/STAR/TAOS-CI/tree/tizen/.github

**Changes proposed in this PR:**
1. Added issue template
2. Added PR template

Signed-off-by: Geunsik Lim <geunsik.lim@samsung.com>
6 years ago[SINK]Update README file of tensor_sink
jinhyuck [Thu, 14 Jun 2018 12:09:48 +0000 (21:09 +0900)]
[SINK]Update README file of tensor_sink

Update README file if tensor_sink for first commit to nnstreamer

Signed-off-by: jinhyuck <jinhyuck83.park@samsung.com>
6 years ago[CI] Add CI server web-address for nnstreamer
Geunsik Lim [Fri, 15 Jun 2018 01:16:22 +0000 (10:16 +0900)]
[CI] Add CI server web-address for nnstreamer

This PR is to append web-address of nnstreamer CI service and enable
the nnstreamer CI server.

**Changes proposed in this PR:**
1. Added webpage link for nnstreamer

Signed-off-by: Geunsik Lim <geunsik.lim@samsung.com>
6 years ago[Codeowners] Update. Add all members for reviewers
MyungJoo Ham [Thu, 14 Jun 2018 23:54:44 +0000 (08:54 +0900)]
[Codeowners] Update. Add all members for reviewers

- Add all members to reviewer list
- Update the comments

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Common] Add .gitignore
MyungJoo Ham [Fri, 15 Jun 2018 00:00:46 +0000 (09:00 +0900)]
[Common] Add .gitignore

Ignore the following files in the git repo:
- cmake build
- golden test generated files
- vi files
- binary (object) files
- ctag

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Decoder] Fix the Bug (#94) and Delete check for SRC direction
jijoong.moon [Thu, 14 Jun 2018 23:45:08 +0000 (08:45 +0900)]
[Decoder] Fix the Bug (#94) and Delete check for SRC direction

- Fix the missing memeory free (#94).
- Delete Check for the GST_PAD_SRC direction. The SRC is ANY, it can
  be Any format and the Sink should be TENSOR Type. Therefore it just
  return GST_TENSOR_CAP_DEFAULT GstCaps.

Signed-off-by: jijoong.moon <jijoong.moon@samsung.com>
6 years agoDoxygen: Create the main page for doxygen generation
Geunsik Lim [Thu, 14 Jun 2018 08:20:01 +0000 (17:20 +0900)]
Doxygen: Create the main page for doxygen generation

This PR is to create the introduction of Main Page  at HTML-based doxygen document.
(e.g., http://aaci.mooo.com/nnstreamer/html/)

**Changes proposed in this PR:**
1. Added Main Page tag

**Self assessment:**
1. GBS build: Okay
2. Local test: Okay

Signed-off-by: Geunsik Lim <geunsik.lim@samsung.com>
6 years ago[Transform] Add tesnsor_transform makrdown title for commit testing
sewon.oh [Thu, 14 Jun 2018 07:38:21 +0000 (16:38 +0900)]
[Transform] Add tesnsor_transform makrdown title for commit testing

- README.md: add title line makrdown file in tensor_transform folder

6 years ago[Decoder] Remove unneeded blank line
Wook Song [Thu, 14 Jun 2018 08:07:01 +0000 (17:07 +0900)]
[Decoder] Remove unneeded blank line

This patch just removes a unneeded blank line.

Signed-off-by: Wook Song <wook16.song@samsung.com>
6 years ago[Tensor Decoder] Add test case
jijoong.moon [Tue, 12 Jun 2018 07:57:25 +0000 (16:57 +0900)]
[Tensor Decoder] Add test case

Add test case for Tensor Decoder. Currently test case which width is
not divided by 4 is not supported.

- Add RGB 640x480

Signed-off-by: jijoong.moon <jijoong.moon@samsung.com>
6 years ago[Converter/Filter] Migrate all testcases into the central test mechanism.
MyungJoo Ham [Thu, 14 Jun 2018 04:38:06 +0000 (13:38 +0900)]
[Converter/Filter] Migrate all testcases into the central test mechanism.

Move rest of tensor_converter/test/* to tests/nnstreamer_converter

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Style] ANSI-C89 Comment Style
MyungJoo Ham [Tue, 12 Jun 2018 06:36:39 +0000 (15:36 +0900)]
[Style] ANSI-C89 Comment Style

https://gstreamer.freedesktop.org/documentation/frequently-asked-questions/developing.html#what-is-the-coding-style-for-gstreamer-code
states:

  Comments should be in /* ANSI C comment style */ and code should generally be compatible with ANSI C89, so please declare all variables at the beginning of the block, etc.

Thus, we have updated commenting style.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Style] Apply gst-indent results to all *.c files
MyungJoo Ham [Thu, 14 Jun 2018 04:27:41 +0000 (13:27 +0900)]
[Style] Apply gst-indent results to all *.c files

nnstreamer.git$ for x in `find -name *.c`; do common/gst-indent $x; done

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Example] Remove examples. They are useless.
MyungJoo Ham [Tue, 12 Jun 2018 06:31:23 +0000 (15:31 +0900)]
[Example] Remove examples. They are useless.

The files are already published in the tutorial web site.
We do not need gst examples in nnstreamer git.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Common] Import gst-indent script from Gstreamer mainline.
MyungJoo Ham [Tue, 12 Jun 2018 06:29:27 +0000 (15:29 +0900)]
[Common] Import gst-indent script from Gstreamer mainline.

Use the script to do coding style check.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Test F/W] gst-launch-based test framework v 1.0
MyungJoo Ham [Tue, 12 Jun 2018 03:19:39 +0000 (12:19 +0900)]
[Test F/W] gst-launch-based test framework v 1.0

nnstreamer_filter_custom is the example test group.

How to use:
- Add a subdirectory under /tests/ representing a test case group
- In the created subdirectory, write "runTest.sh" with given APIs in testAPI.sh

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[converter, filter] Reduce log messages
MyungJoo Ham [Tue, 12 Jun 2018 01:37:22 +0000 (10:37 +0900)]
[converter, filter] Reduce log messages

Emit debug/log messages when proper options are given only.
Do not write such messages when no options are specified.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Dist] Run unittest for filter/custom/1 with gbs
MyungJoo Ham [Mon, 11 Jun 2018 09:45:11 +0000 (18:45 +0900)]
[Dist] Run unittest for filter/custom/1 with gbs

Add the new filter/custom/1 testcase as a unittest during the build

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Filter/Custom] Add testcase. Fix bugs found by the testcase.
MyungJoo Ham [Mon, 11 Jun 2018 09:33:37 +0000 (18:33 +0900)]
[Filter/Custom] Add testcase. Fix bugs found by the testcase.

1. Added "passthrough with 3x280x4 tensors" Custom Filter Example
2. Added test case with the example.
3. Fixed filter/custom bugs with the test case
4. Relocated headers and their install paths

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Filter/Main] First working prototype of filter::main
MyungJoo Ham [Fri, 8 Jun 2018 06:02:01 +0000 (15:02 +0900)]
[Filter/Main] First working prototype of filter::main

The full execution path of tensor_filter::main is tested with testcase-01
although it does not process anything in the model.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Decoder] Tensor Decoder Draft
jijoong.moon [Tue, 12 Jun 2018 07:50:50 +0000 (16:50 +0900)]
[Decoder] Tensor Decoder Draft

The Tensor Decoder revert tensor to media type.
It takes tensor as input and produce media data type. Currently only
video/x-raw supports.

Signed-off-by: jijoong.moon <jijoong.moon@samsung.com>
6 years ago[Filter/Main] Caps Negotiations Implemented
MyungJoo Ham [Thu, 7 Jun 2018 10:00:43 +0000 (19:00 +0900)]
[Filter/Main] Caps Negotiations Implemented

It appears that the simple test case of "videosrctest --> t_converter --> t_filter --> fakesink" works up to caps-negotiations & fixating caps.

Test Case:

gst-launch-1.0 -v --gst-debug=GST_CAPS:4 --gst-plugin-path=${PATH_TO_PLUGIN} videotestsrc num-buffers=1 ! video/x-raw,format=RGB,width=280,height=40,framerate=0/1 ! videoconvert ! video/x-raw, format=BGRx ! tensor_converter silent=FALSE ! tensor_filter debug=TRUE framework='tensorflow-lite' model='./nothing' input='4:280:40' inputtype='uint8' output='1' outputtype='uint8' ! filesink location="test.bgrx.log" sync=true

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Filter/Main] Restrict pad-caps when set-property gives enough information.
MyungJoo Ham [Mon, 4 Jun 2018 12:19:57 +0000 (21:19 +0900)]
[Filter/Main] Restrict pad-caps when set-property gives enough information.

With dimension/type information is available via set-property,
restrict pad-caps accordingly before calling set-caps callbacks.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Documentation] How to write test cases
MyungJoo Ham [Tue, 12 Jun 2018 04:41:26 +0000 (13:41 +0900)]
[Documentation] How to write test cases

1. How to write gst-launch based test cases
2. How to write gtest based test cases

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Converter] Fix non-in-place (memcpy mode) and add test case for it.
MyungJoo Ham [Thu, 7 Jun 2018 11:15:05 +0000 (20:15 +0900)]
[Converter] Fix non-in-place (memcpy mode) and add test case for it.

Non inplace mode (memcpy mode) is fixed and tested.

Testcase 03 for converter tests memcpy mode.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Common] Commonize default pad-caps for other/tensor
MyungJoo Ham [Tue, 5 Jun 2018 08:58:28 +0000 (17:58 +0900)]
[Common] Commonize default pad-caps for other/tensor

We may be changing the default pad-caps for other/tensor later.
Make it refer to the same code.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Bug Fix] Using memmove for in-place calculation
jijoong.moon [Tue, 5 Jun 2018 08:51:48 +0000 (17:51 +0900)]
[Bug Fix] Using memmove for in-place calculation

Sometimes there is undefined behavior when the source and destination overlaped.
In this case, we have to use memmove to handle overlapping regions.

Signed-off-by: jijoong.moon <jijoong.moon@samsung.com>
6 years ago[Filter/Custom] Custom tensor postprocessing support
MyungJoo Ham [Fri, 1 Jun 2018 04:46:27 +0000 (13:46 +0900)]
[Filter/Custom] Custom tensor postprocessing support

NN developers may define their own custom tensor operations
in the format given byu tensor_common to let NNStreamer
do any custom operations on the tensor stream.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Filter/Main] Parse all properties.
MyungJoo Ham [Thu, 31 May 2018 11:54:34 +0000 (20:54 +0900)]
[Filter/Main] Parse all properties.

1. Complete property parsing code
2. Did a little bit of refactoring & doxygen entry filling

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Unittest] Enable unittest coverage anaysis
MyungJoo Ham [Mon, 4 Jun 2018 05:09:50 +0000 (14:09 +0900)]
[Unittest] Enable unittest coverage anaysis

Use TAOS-CI to generate unittest coverage analysis html pages.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Common] Add dimension property parsing API
MyungJoo Ham [Thu, 31 May 2018 11:49:14 +0000 (20:49 +0900)]
[Common] Add dimension property parsing API

Let's use dimension parsing API in tensor_filter

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Common] Add get_tensor_type, find_key_strv internal API.
MyungJoo Ham [Thu, 31 May 2018 08:32:26 +0000 (17:32 +0900)]
[Common] Add get_tensor_type, find_key_strv internal API.

1. Added get_tensor_type API for plugins to parse properties
2. Added unittest cases.

get_tensor_type may be implemented with find_key_strv, but, let's
use this "faster" for type property finder.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Filter] Add more property processing
MyungJoo Ham [Thu, 31 May 2018 10:03:47 +0000 (19:03 +0900)]
[Filter] Add more property processing

1. Filter/Main: add property handling for more properites
2. Filter/TF-Lite: updated callback definitions

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Convert] Support RSTRIDE = RU4 Cases (RGB && width%4>0)
MyungJoo Ham [Thu, 24 May 2018 02:19:56 +0000 (11:19 +0900)]
[Convert] Support RSTRIDE = RU4 Cases (RGB && width%4>0)

Most (if not all) video/x-raw formats align data with 4-bytes for each
image row.

E.g., if image width = 642 and colorspace = RGB, video/x-raw adds
two zero-bytes for each row's end.

The tensor array should not have such zero-padding; thus
this commit supports zero-padding removal.

However, such operation costs one additional full memcpy; thus,
having such stream input must be discouraged.

This commit includes:
1. Support zero-padding removal
2. Added warnings when zero-paddings exists in the source streams.

Fixes #7

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[DIST] Support Tizen's GST Extra Plugins
MyungJoo Ham [Thu, 31 May 2018 02:18:29 +0000 (11:18 +0900)]
[DIST] Support Tizen's GST Extra Plugins

This requires https://review.tizen.org/gerrit/#/c/180570/ be merged and SR'ed by Tizen Team.
Then, we will be able to run unit tests in Tizen infrastructure.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Convert] Use common header. Remove redundant content
MyungJoo Ham [Tue, 29 May 2018 02:35:49 +0000 (11:35 +0900)]
[Convert] Use common header. Remove redundant content

Use <tensor_common.h> for common data types.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[README] Update contents
MyungJoo Ham [Fri, 1 Jun 2018 01:12:05 +0000 (10:12 +0900)]
[README] Update contents

Updated readme contents with recent status.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Build] Enforce -Wall / -Werror
MyungJoo Ham [Tue, 29 May 2018 04:22:22 +0000 (13:22 +0900)]
[Build] Enforce -Wall / -Werror

Let's not tolerate compiler warnings in this project from now on.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Common] Fix build errors
MyungJoo Ham [Tue, 29 May 2018 04:54:46 +0000 (13:54 +0900)]
[Common] Fix build errors

Somehow I've missed build errors between PRs

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Filter/Main] Revise data type for NNFW plugins
MyungJoo Ham [Tue, 29 May 2018 03:51:12 +0000 (12:51 +0900)]
[Filter/Main] Revise data type for NNFW plugins

- Add input/output dimension get methods
- Add NNFW plugin private data

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Filter/Main] Fill in get/set property functions
MyungJoo Ham [Tue, 29 May 2018 02:27:24 +0000 (11:27 +0900)]
[Filter/Main] Fill in get/set property functions

Fill in get/set property functions so that we can use tensor_filter from gst apps

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[DIST] Revise .spec and licenses
MyungJoo Ham [Tue, 29 May 2018 01:33:42 +0000 (10:33 +0900)]
[DIST] Revise .spec and licenses

Add license files and have manifest files installed.
Add defattr as well.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[DIST] Skip testcase generation in Tizen GBS/OBS.
MyungJoo Ham [Tue, 29 May 2018 01:19:49 +0000 (10:19 +0900)]
[DIST] Skip testcase generation in Tizen GBS/OBS.

Testcase Generation of Tensor_Converter requires PIL and TK, which are removed from Tizen and I do not want to add them just for unit testing.

Note that in order to pass unit tests, we need #14 merged.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Filter/Main] Skeleton/Draft Code Template Added
MyungJoo Ham [Thu, 24 May 2018 12:01:32 +0000 (21:01 +0900)]
[Filter/Main] Skeleton/Draft Code Template Added

This is the starting point for tensor_filter/main.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Convert] Add test cases based on randomly generated PNG files
MyungJoo Ham [Thu, 17 May 2018 11:09:45 +0000 (20:09 +0900)]
[Convert] Add test cases based on randomly generated PNG files

1. Test more input sources
2. Test with offset case
3. Added doxygen entries

(Updated with test case 2 fix for the cases where width % 4 > 0)

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Source] Add directory and README.
MyungJoo Ham [Fri, 25 May 2018 06:08:42 +0000 (15:08 +0900)]
[Source] Add directory and README.

A new element for NNStreamer is drafted in the architecture document.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Filter] Add Readme entry for developers.
MyungJoo Ham [Mon, 28 May 2018 06:54:07 +0000 (15:54 +0900)]
[Filter] Add Readme entry for developers.

Basic requirements for tensor_filter component are described.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[DIST] Add .spec for gbs/obs builds
MyungJoo Ham [Wed, 23 May 2018 07:36:24 +0000 (16:36 +0900)]
[DIST] Add .spec for gbs/obs builds

Added .spec / .manifest for gbs/obs builds

Fixes #10

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[CI] Update codeowners
MyungJoo Ham [Fri, 25 May 2018 05:27:28 +0000 (14:27 +0900)]
[CI] Update codeowners

Add more people as reviewers.
No per-module policy. (we don't need it yet.)

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years agoAdd CMakeLists.txt for gst_examples
jijoong.moon [Fri, 25 May 2018 02:40:34 +0000 (11:40 +0900)]
Add CMakeLists.txt for gst_examples

For convience, CMakeLists.txt is added in gst_example.

Signed-off-by: jijoong.moon <jijoong.moon@samsung.com>
6 years ago[Build] Make a central CMake file for all plugins
MyungJoo Ham [Wed, 23 May 2018 11:05:48 +0000 (20:05 +0900)]
[Build] Make a central CMake file for all plugins

Let's build from a single point. This make it faster to build as well as having the common configuration across all the plugins.

Fixes #19

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Common] Add a common header
MyungJoo Ham [Wed, 23 May 2018 10:19:25 +0000 (19:19 +0900)]
[Common] Add a common header

This commit only declares the new "common header".

We need to modify tensor_converter to use this common header later
after merging the pending PRs (#12, #13, #14, #15, #17).

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years agoAdd subdirectories for all designed components.
MyungJoo Ham [Wed, 23 May 2018 03:20:10 +0000 (12:20 +0900)]
Add subdirectories for all designed components.

Added according to http://suprem.sec.samsung.net/confluence/display/STAR/NNStreamer+Interface+Internal+Draft+1803B

Fixes #11

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Convert] Rename convert2tensor to tensor_converter
MyungJoo Ham [Wed, 23 May 2018 02:39:53 +0000 (11:39 +0900)]
[Convert] Rename convert2tensor to tensor_converter

Renamed the module according to the architecture design.
http://suprem.sec.samsung.net/confluence/display/STAR/NNStreamer+Interface+Internal+Draft+1803B

Fixes #11

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[CI] Add CodeOwners Entries
MyungJoo Ham [Thu, 24 May 2018 07:41:37 +0000 (16:41 +0900)]
[CI] Add CodeOwners Entries

Initial codeowner entries for nnstreamer.

We need to fill this in with more people and directories as we progress.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Convert] Add some doxygen entries
MyungJoo Ham [Wed, 23 May 2018 10:11:16 +0000 (19:11 +0900)]
[Convert] Add some doxygen entries

Add doxygen entires especially on the data structures sharable to other elements.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[README] Add basic contents for README
MyungJoo Ham [Fri, 18 May 2018 01:28:15 +0000 (10:28 +0900)]
[README] Add basic contents for README

Objectives, Components, How-to-* entries are added.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Convert] Support BGRx format for video.
MyungJoo Ham [Mon, 14 May 2018 08:28:08 +0000 (17:28 +0900)]
[Convert] Support BGRx format for video.

Support BGRx in additional to RGB format.

How to test:

$ gst-launch-1.0 --gst-plugin-path=/source/AutoDrv/NNStreamer/convert2tensor/build videotestsrc ! video/x-raw,format=RGB,width=280,height=40,framerate=1/1 ! tee name=t ! queue ! videoconvert ! video/x-raw, format=BGRx ! convert2tensor ! filesink location="test.bgrx.log" sync=true t. ! queue ! filesink location="test.rgb.log" sync=true

If the resulting test.rgb.log has rgb format and test.bgrx.log has bgrx format, then it's good to go.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Convert] Add test case with videosrctest
MyungJoo Ham [Thu, 17 May 2018 09:11:40 +0000 (18:11 +0900)]
[Convert] Add test case with videosrctest

TODO: Add png based test, which fails with the current code (we need to fix it!)

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Convert] Tested and fixed with videotestsrc
MyungJoo Ham [Mon, 2 Apr 2018 07:24:06 +0000 (16:24 +0900)]
[Convert] Tested and fixed with videotestsrc

This is not an issue. Don't be alarmed.
- Regardless of videotestsrc framerate, convert2tensor gives ~1000 FPS outputs.
  . This happens when a sink-element attached at the src-pad of this element is not synching. Add sync option to the sink element.

How-to-test:
$ gst-launch-1.0 --gst-plugin-path=/PATH_TO_BUILT_SO videotestsrc ! video/x-raw,width=280,height=40,framerate=1/1 ! convert2tensor ! filesink location="test.log" sync=true

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Convert] Implement two negotiation methods.
MyungJoo Ham [Thu, 29 Mar 2018 08:01:16 +0000 (17:01 +0900)]
[Convert] Implement two negotiation methods.

Implement transform_caps / fixate_caps referring gstvideoconvert.c

set_caps() will be implemented tomorrow.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Convert] Apply x-raw/RGB format data structure.
MyungJoo Ham [Thu, 29 Mar 2018 02:33:30 +0000 (11:33 +0900)]
[Convert] Apply x-raw/RGB format data structure.

Data of x-raw/RGB is:

[height][width][RGB] and width has padding with stride = 4.

Thus, tensor output of convert2tensor generates width = 4 x N with zero-padding.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Convert] Implement Processing part from the document
MyungJoo Ham [Wed, 28 Mar 2018 06:38:24 +0000 (15:38 +0900)]
[Convert] Implement Processing part from the document

From the document, https://gstreamer.freedesktop.org/documentation/design/element-transform.html
implement "Processing" part.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Convert] Added skeletons for GstBaseTransform class
MyungJoo Ham [Wed, 28 Mar 2018 02:03:25 +0000 (11:03 +0900)]
[Convert] Added skeletons for GstBaseTransform class

Added null impementation of virtual methods of GstBaseTransform

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Convert] Change base class from "GstElement" to "GstBaseTransform"
MyungJoo Ham [Wed, 28 Mar 2018 01:44:59 +0000 (10:44 +0900)]
[Convert] Change base class from "GstElement" to "GstBaseTransform"

Let's use more advanced infrastructure, "GstBaseTranform".
Convert2Tensor is a transformer!

https://gstreamer.freedesktop.org/documentation/design/element-transform.html

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Converter] Get tensor metadata from sinkpad when it is created.
MyungJoo Ham [Tue, 27 Mar 2018 10:46:36 +0000 (19:46 +0900)]
[Converter] Get tensor metadata from sinkpad when it is created.

Sinkpad is created when a source element is attached to this filter (convert2filter).
Convert2filter becomes aware of its metadata (dimensions of tensor) at this point.
Thus, configure the metadata with the event handler.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Converter] Converter Core Function Located
MyungJoo Ham [Tue, 27 Mar 2018 07:59:32 +0000 (16:59 +0900)]
[Converter] Converter Core Function Located

Fill in gst_convert2tensor_sink_event to convert media data to tensors.
GST Tensor is to be defined with gst_convert2tensor_configure_tensor

Build Tested.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Converter] GST Plugin Tutorial 1 (Boilerplate) Followed.
MyungJoo Ham [Mon, 26 Mar 2018 12:39:29 +0000 (21:39 +0900)]
[Converter] GST Plugin Tutorial 1 (Boilerplate) Followed.

Standard Tensor Media Type Draft Applied as well.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Converter] GST Plugin Template Created
MyungJoo Ham [Mon, 26 Mar 2018 11:44:34 +0000 (20:44 +0900)]
[Converter] GST Plugin Template Created

An empty template for GST Plugin, "Convert2Tensor".

1. This is to draft & verify "other/tensor" GST type design.
2. Then, this will work as converter from media sources for NN filters.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Gst Example] tutorial-8
MyungJoo Ham [Mon, 26 Mar 2018 11:43:48 +0000 (20:43 +0900)]
[Gst Example] tutorial-8

GST Official Tutorial 8

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Gst Example] tutorial-6 and 7
MyungJoo Ham [Mon, 26 Mar 2018 04:54:36 +0000 (13:54 +0900)]
[Gst Example] tutorial-6 and 7

Added tutorial 6 and 7

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Gst Example] tutorial-3 and 3-exercise
MyungJoo Ham [Thu, 22 Mar 2018 09:46:49 +0000 (18:46 +0900)]
[Gst Example] tutorial-3 and 3-exercise

Dynamic stream construction.

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Gst Exmaple] tutorial 2 and 2 + add-filter exercise
MyungJoo Ham [Thu, 22 Mar 2018 04:56:23 +0000 (13:56 +0900)]
[Gst Exmaple] tutorial 2 and 2 + add-filter exercise

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years agoFix typo in the tutorial example with the address
MyungJoo Ham [Thu, 22 Mar 2018 04:55:48 +0000 (13:55 +0900)]
Fix typo in the tutorial example with the address

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years ago[Gst Example] tutorial 1
MyungJoo Ham [Thu, 22 Mar 2018 02:06:43 +0000 (11:06 +0900)]
[Gst Example] tutorial 1

Learning https://gstreamer.freedesktop.org/documentation/tutorials/basic/hello-world.html

Signed-off-by: MyungJoo Ham <myungjoo.ham@samsung.com>
6 years agoInitial commit
함명주/동작제어Lab(SR)/Principal Engineer/삼성전자 [Thu, 22 Mar 2018 02:02:26 +0000 (11:02 +0900)]
Initial commit