All of lore.kernel.org
 help / color / mirror / Atom feed
From: Denys Dmytriyenko <denys@ti.com>
To: "Stiffler, Jacob" <j-stiffler@ti.com>
Cc: "meta-arago@arago-project.org" <meta-arago@arago-project.org>,
	"Senicic, Djordje" <d-senicic1@ti.com>
Subject: Re: [EXTERNAL] [meta-processor-sdk][PATCHv2] neo-ai-dlr: Add TIDL support on top of meta-aws neo-ai-dlr
Date: Thu, 12 Dec 2019 19:35:44 -0500	[thread overview]
Message-ID: <20191213003544.GL32050@beryl> (raw)
In-Reply-To: <b106da709dfd46df93a6a11c3de7e64c@ti.com>

It's better to use git format-patch with those -M -C options and then examine 
the resulting patch file before sending it with git send-email.

And both -C and -M take similarity index:

       -M[<n>], --find-renames[=<n>]
           Detect renames. If n is specified, it is a threshold on the 
           similarity index (i.e. amount of addition/deletions compared to 
           the file’s size). For example, -M90% means Git should consider a 
           delete/add pair to be a rename if more than 90% of the file hasn’t 
           changed. Without a % sign, the number is to be read as a fraction, 
           with a decimal point before it. I.e., -M5 becomes 0.5, and is thus 
           the same as -M50%. Similarly, -M05 is the same as -M5%. To limit 
           detection to exact renames, use -M100%. The default similarity 
           index is 50%.

       -C[<n>], --find-copies[=<n>]
           Detect copies as well as renames. See also --find-copies-harder. If 
           n is specified, it has the same meaning as for -M<n>.

-- 
Denys


On Thu, Dec 12, 2019 at 11:46:05PM +0000, Stiffler, Jacob wrote:
> This did not work. The exact command I use to compare the difference is:
> 
> git send-email --to="meta-arago@arago-project.org" --confirm=always --annotate -M -C01 HEAD~1
> 
> Thanks,
> Jake
> 
> -----Original Message-----
> From: meta-arago-bounces@arago-project.org [mailto:meta-arago-bounces@arago-project.org] On Behalf Of Senicic, Djordje
> Sent: Thursday, December 12, 2019 6:36 PM
> To: meta-arago@arago-project.org
> Cc: Senicic, Djordje
> Subject: [EXTERNAL] [meta-arago] [meta-processor-sdk][PATCHv2] neo-ai-dlr: Add TIDL support on top of meta-aws neo-ai-dlr
> 
> - Add support for custom TIDL inference relay node
> - Use github.com/TexasInstruments repositories
> - Include CPP live demo and Python file-to-stdout inference scripts
> 
> Signed-off-by: Djordje Senicic <d-senicic1@ti.com>
> ---
>  .../neo-ai-dlr/neo-ai-dlr.bbappend            | 64 +++++++++++++++
>  ...akeLists-skip-cloning-of-googletests.patch | 54 -------------
>  recipes-support/neo-ai/neo-ai-dlr_git.bb      | 77 -------------------
>  3 files changed, 64 insertions(+), 131 deletions(-)
>  create mode 100644 recipes-support/neo-ai-dlr/neo-ai-dlr.bbappend
>  delete mode 100644 recipes-support/neo-ai/files/0001-CMakeLists-skip-cloning-of-googletests.patch
>  delete mode 100644 recipes-support/neo-ai/neo-ai-dlr_git.bb
> 
> diff --git a/recipes-support/neo-ai-dlr/neo-ai-dlr.bbappend b/recipes-support/neo-ai-dlr/neo-ai-dlr.bbappend
> new file mode 100644
> index 0000000..50895b2
> --- /dev/null
> +++ b/recipes-support/neo-ai-dlr/neo-ai-dlr.bbappend
> @@ -0,0 +1,64 @@
> +PR_append = ".int0"
> +
> +LIC_FILES_CHKSUM = "file://LICENSE;md5=34400b68072d710fecd0a2940a0d1658 \
> +                    file://3rdparty/tvm/LICENSE;md5=f563935cf80d1c889dd958372e9ea7c4 \
> +                    file://3rdparty/tvm/3rdparty/dmlc-core/LICENSE;md5=0ca7d6e8f4af26868cb42025ad83374b \
> +                    file://3rdparty/tvm/3rdparty/dlpack/LICENSE;md5=f62d4e85ba68a1574b74d97ab8dea9ab \
> +                    file://3rdparty/treelite/LICENSE;md5=34400b68072d710fecd0a2940a0d1658 \
> +                    file://3rdparty/treelite/dmlc-core/LICENSE;md5=0ca7d6e8f4af26868cb42025ad83374b \
> +                    file://3rdparty/treelite/3rdparty/fmt/LICENSE.rst;md5=af88d758f75f3c5c48a967501f24384b \
> +                    file://3rdparty/treelite/3rdparty/protobuf/LICENSE;md5=37b5762e07f0af8c74ce80a8bda4266b \
> +                    file://3rdparty/treelite/3rdparty/protobuf/third_party/benchmark/LICENSE;md5=3b83ef96387f14655fc854ddc3c6bd57 \
> +                    file://3rdparty/treelite/3rdparty/protobuf/third_party/googletest/LICENSE;md5=cbbd27594afd089daa160d3a16dd515a \
> +"
> +
> +PV = "1.01"
> +
> +DEPENDS += " opencv "
> +
> +BRANCH-NEO-AI-DLR = "dev"
> +BRANCH-NEO-TVM = "dev"
> +
> +# Main DLR sources plus submodules (and submodules of submodules).
> +SRC_URI = "git://github.com/TexasInstruments/neo-ai-dlr;protocol=https;branch=${BRANCH-NEO-AI-DLR};name=neo-ai-dlr \
> +           git://github.com/TexasInstruments/tvm;protocol=https;branch=${BRANCH-NEO-TVM};destsuffix=${S}/3rdparty/tvm;name=neo-ai-tvm \
> +           git://github.com/dmlc/dmlc-core;protocol=https;branch=master;destsuffix=${S}/3rdparty/tvm/3rdparty/dmlc-core;name=neo-ai-tvm-dmlc-core \
> +           git://github.com/dmlc/dlpack;protocol=https;branch=master;destsuffix=${S}/3rdparty/tvm/3rdparty/dlpack;name=neo-ai-tvm-dlpack \
> +           git://github.com/agauniyal/rang;protocol=https;branch=master;destsuffix=${S}/3rdparty/tvm/3rdparty/rang;name=neo-ai-tvm-rang \
> +           git://github.com/neo-ai/treelite;protocol=https;branch=master;destsuffix=${S}/3rdparty/treelite;name=neo-ai-treelite \
> +           git://github.com/dmlc/dmlc-core;protocol=https;branch=master;destsuffix=${S}/3rdparty/treelite/dmlc-core;name=neo-ai-treelite-dmlc-core \
> +           git://github.com/fmtlib/fmt;protocol=https;nobranch=1;destsuffix=${S}/3rdparty/treelite/3rdparty/fmt;name=neo-ai-treelite-fmt \
> +           git://github.com/google/protobuf;protocol=https;nobranch=1;destsuffix=${S}/3rdparty/treelite/3rdparty/protobuf;name=neo-ai-treelite-protobuf \
> +           git://github.com/google/benchmark;protocol=https;nobranch=1;destsuffix=${S}/3rdparty/treelite/3rdparty/protobuf/third_party/benchmark;name=neo-ai-treelite-protobuf-benchmark \
> +           git://github.com/google/googletest;protocol=https;nobranch=1;destsuffix=${S}/3rdparty/treelite/3rdparty/protobuf/third_party/googletest;name=neo-ai-treelite-protobuf-googletest \
> +"
> +
> +SRCREV_neo-ai-dlr = "40394be2e39eaa6248f9bf0a1143692083c0e3d2"
> +SRCREV_neo-ai-tvm = "11f0a9d2349b94a733aae1c8bd652e6055f4b185"
> +SRCREV_neo-ai-tvm-dmlc-core = "ca9f9329654dbd42f06988276c6f74eb8bdd5038"
> +SRCREV_neo-ai-tvm-dlpack = "b7bd45cdd8b67f4ab2502a8717f2e0926d9b4121"
> +SRCREV_neo-ai-tvm-rang = "cabe04d6d6b05356fa8f9741704924788f0dd762"
> +
> +SRCREV_neo-ai-treelite = "938af7867641fb09a8c93aadb66587ad9cbed9c2"
> +SRCREV_neo-ai-treelite-dmlc-core = "ec147925f1daccee6a33796880935f9cec8541cf"
> +SRCREV_neo-ai-treelite-fmt = "9f2e7edaebccf8f271cec5e855cce1223ff3e6d6"
> +SRCREV_neo-ai-treelite-protobuf = "6d087c256c8ab04b3a1a9832746e9c3a8d3afd79"
> +SRCREV_neo-ai-treelite-protobuf-benchmark = "360e66c1c4777c99402cf8cd535aa510fee16573"
> +SRCREV_neo-ai-treelite-protobuf-googletest = "78fdd6c00b8fa5dd67066fbb796affc87ba0e075"
> +
> +do_compile_append() {
> +   ninja demo
> +   ninja democv
> +}
> +
> +
> +do_install_append() {
> +
> +    # Now install additional python test scripts, bash scripts and precomputed models
> +    install -d ${D}${datadir}/dlr/demos
> +    cp -Prf --preserve=mode,timestamps ${S}/examples/tidl/* ${D}${datadir}/dlr/demos
> +    install -m 0755 ${B}/bin/* ${D}${datadir}/dlr/demos/.
> +}
> +
> +RDEPENDS_${PN} =+ " tidl-api "
> +FILES_${PN}-tests += "${datadir}/dlr/demos"
> diff --git a/recipes-support/neo-ai/files/0001-CMakeLists-skip-cloning-of-googletests.patch b/recipes-support/neo-ai/files/0001-CMakeLists-skip-cloning-of-googletests.patch
> deleted file mode 100644
> index b7d3c85..0000000
> --- a/recipes-support/neo-ai/files/0001-CMakeLists-skip-cloning-of-googletests.patch
> +++ /dev/null
> @@ -1,54 +0,0 @@
> -From 3d9fa328598b38022c638b402d111000ce0d88c7 Mon Sep 17 00:00:00 2001
> -From: Jianzhong Xu <xuj@ti.com>
> -Date: Tue, 26 Nov 2019 08:53:33 -0500
> -Subject: [PATCH] CMakeLists: skip cloning of googletests
> -
> -Signed-off-by: Jianzhong Xu <xuj@ti.com>
> -
> -Upstream-status: Inappropriate (OE-specific)
> -* googletest should be obtained as a proper dependency
> -
> ----
> - CMakeLists.txt | 26 +++++++++++++-------------
> - 1 file changed, 13 insertions(+), 13 deletions(-)
> -
> -diff --git a/CMakeLists.txt b/CMakeLists.txt
> -index 281fdb7..70a88d7 100644
> ---- a/CMakeLists.txt
> -+++ b/CMakeLists.txt
> -@@ -293,19 +293,19 @@ add_custom_target(demo DEPENDS ${DEMO_EXECS})
> - 
> - # Tests
> - if(NOT(ANDROID_BUILD OR AAR_BUILD))
> --  include(cmake/googletest.cmake)
> --  fetch_googletest(
> --    ${PROJECT_SOURCE_DIR}/cmake
> --    ${PROJECT_BINARY_DIR}/googletest
> --    )
> --
> --  enable_testing()
> --
> --  file(GLOB TEST_SRCS tests/cpp/*.cc)
> --  if(WITH_TENSORFLOW_LITE_LIB)
> --    file(GLOB TFLITE_TEST_SRCS tests/cpp/dlr_tflite/*.cc)
> --    list(APPEND TEST_SRCS ${TFLITE_TEST_SRCS})
> --  endif()
> -+  #include(cmake/googletest.cmake)
> -+  #fetch_googletest(
> -+  #  ${PROJECT_SOURCE_DIR}/cmake
> -+  #  ${PROJECT_BINARY_DIR}/googletest
> -+  #  )
> -+  #
> -+  #enable_testing()
> -+  #
> -+  #file(GLOB TEST_SRCS tests/cpp/*.cc)
> -+  #if(WITH_TENSORFLOW_LITE_LIB)
> -+  #  file(GLOB TFLITE_TEST_SRCS tests/cpp/dlr_tflite/*.cc)
> -+  #  list(APPEND TEST_SRCS ${TFLITE_TEST_SRCS})
> -+  #endif()
> -   foreach(__srcpath ${TEST_SRCS})
> -     get_filename_component(__srcname ${__srcpath} NAME)
> -     string(REPLACE ".cc" "" __execname ${__srcname})
> --- 
> -2.17.1
> -
> diff --git a/recipes-support/neo-ai/neo-ai-dlr_git.bb b/recipes-support/neo-ai/neo-ai-dlr_git.bb
> deleted file mode 100644
> index 636714a..0000000
> --- a/recipes-support/neo-ai/neo-ai-dlr_git.bb
> +++ /dev/null
> @@ -1,77 +0,0 @@
> -SUMMARY = "NEO-AI Deep Learning Runtime"
> -DESCRIPTION = "Neo-AI-DLR is a common runtime for machine learning models compiled by AWS SageMaker Neo, TVM, or TreeLite."
> -HOMEPAGE = "https://aws.amazon.com/sagemaker/neo/"
> -LICENSE = "Apache-2.0 & BSD-3-Clause"
> -
> -LIC_FILES_CHKSUM = "file://LICENSE;md5=34400b68072d710fecd0a2940a0d1658 \
> -                    file://3rdparty/tvm/LICENSE;md5=e3fc50a88d0a364313df4b21ef20c29e \
> -                    file://3rdparty/tvm/3rdparty/dmlc-core/LICENSE;md5=0ca7d6e8f4af26868cb42025ad83374b \
> -                    file://3rdparty/tvm/3rdparty/dlpack/LICENSE;md5=f62d4e85ba68a1574b74d97ab8dea9ab \
> -                    file://3rdparty/tvm/3rdparty/HAlideIR/LICENSE;md5=9910386e68f0616e1ecf1037479fa97e \
> -                    file://3rdparty/treelite/LICENSE;md5=34400b68072d710fecd0a2940a0d1658 \
> -                    file://3rdparty/treelite/dmlc-core/LICENSE;md5=0ca7d6e8f4af26868cb42025ad83374b \
> -                    file://3rdparty/treelite/3rdparty/fmt/LICENSE.rst;md5=c2e38bc8629eac247a73b65c1548b2f0 \
> -"
> -
> -PV = "1.0"
> -
> -BRANCH ?= "master"
> -
> -# Main DLR sources plus submodules (and submodules of submodules).
> -SRC_URI = "git://github.com/neo-ai/neo-ai-dlr;protocol=https;branch=${BRANCH};name=neo-ai-dlr \
> -           git://github.com/neo-ai/tvm;protocol=https;branch=stable;destsuffix=${S}/3rdparty/tvm;name=neo-ai-tvm \
> -           git://github.com/dmlc/dmlc-core;protocol=https;branch=master;destsuffix=${S}/3rdparty/tvm/3rdparty/dmlc-core;name=neo-ai-tvm-dmlc-core \
> -           git://github.com/dmlc/dlpack;protocol=https;branch=master;destsuffix=${S}/3rdparty/tvm/3rdparty/dlpack;name=neo-ai-tvm-dlpack \
> -           git://github.com/dmlc/HalideIR;protocol=https;branch=master;destsuffix=${S}/3rdparty/tvm/3rdparty/HAlideIR;name=neo-ai-tvm-halideir \
> -           git://github.com/neo-ai/treelite;protocol=https;branch=master;destsuffix=${S}/3rdparty/treelite;name=neo-ai-treelite \
> -           git://github.com/dmlc/dmlc-core;protocol=https;branch=master;destsuffix=${S}/3rdparty/treelite/dmlc-core;name=neo-ai-treelite-dmlc-core \
> -           git://github.com/fmtlib/fmt;protocol=https;nobranch=1;destsuffix=${S}/3rdparty/treelite/3rdparty/fmt;name=neo-ai-treelite-fmt \
> -           file://0001-CMakeLists-skip-cloning-of-googletests.patch \
> -"
> -
> -SRCREV_neo-ai-dlr = "35ed4fa2607056608451d85508fea70f458a14a6"
> -SRCREV_neo-ai-tvm = "44779571412930681eef9e8b9d32aa845b8cc5ad"
> -SRCREV_neo-ai-tvm-dmlc-core = "4d49691f1a9d944c3b0aa5e63f1db3cad1f941f8"
> -SRCREV_neo-ai-tvm-dlpack = "bee4d1dd8dc1ee4a1fd8fa6a96476c2f8b7492a3"
> -SRCREV_neo-ai-tvm-halideir = "e4a4c02764d37c9c3db0d64c4996651a3ef9513c"
> -SRCREV_neo-ai-treelite = "0972ce97687b4a1fb1262fad56232e7cc61116eb"
> -SRCREV_neo-ai-treelite-dmlc-core = "4d49691f1a9d944c3b0aa5e63f1db3cad1f941f8"
> -SRCREV_neo-ai-treelite-fmt = "135ab5cf71ed731fc9fa0653051e7d4884a3652f"
> -
> -S = "${WORKDIR}/git"
> -
> -inherit setuptools3 cmake python3native
> -
> -# Set B so that DLR Python installation can find the library
> -B = "${S}/build"
> -
> -do_install() {
> -    # This does not do anything
> -    #cmake_do_install
> -
> -    install -d ${D}${includedir}/dlr_tflite
> -    install -m 0644 ${S}/include/*.h ${D}${includedir}
> -    install -m 0644 ${S}/include/dlr_tflite/*.h ${D}${includedir}/dlr_tflite
> -
> -    # Install DLR Python binding
> -    cd ${S}/python
> -    distutils3_do_install
> -
> -    # setup.py install some libs under datadir, but we don't need them, so remove.
> -    rm ${D}${datadir}/dlr/*.so
> -
> -    # Install DLR library to Python import search path
> -    install -m 0644 ${S}/build/lib/libdlr.so ${D}${PYTHON_SITEPACKAGES_DIR}/dlr
> -
> -    # Now install python test scripts
> -    install -d ${D}${datadir}/dlr/tests/python/integration
> -    install -m 0644 ${S}/tests/python/integration/*.py ${D}${datadir}/dlr/tests/python/integration
> -    install -m 0644 ${S}/tests/python/integration/*.npy ${D}${datadir}/dlr/tests/python/integration
> -}
> -
> -PACKAGES =+ "${PN}-tests"
> -FILES_${PN}-tests = "${datadir}/dlr/tests"
> -RDEPENDS_${PN}-tests += "${PN}"
> -
> -# Versioned libs are not produced
> -FILES_SOLIBSDEV = ""
> -- 
> 2.17.1
> 
> _______________________________________________
> meta-arago mailing list
> meta-arago@arago-project.org
> http://arago-project.org/cgi-bin/mailman/listinfo/meta-arago
> _______________________________________________
> meta-arago mailing list
> meta-arago@arago-project.org
> http://arago-project.org/cgi-bin/mailman/listinfo/meta-arago


      reply	other threads:[~2019-12-13  0:37 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-12-12 23:35 [meta-processor-sdk][PATCHv2] neo-ai-dlr: Add TIDL support on top of meta-aws neo-ai-dlr Djordje Senicic
2019-12-12 23:46 ` [EXTERNAL] " Stiffler, Jacob
2019-12-13  0:35   ` Denys Dmytriyenko [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20191213003544.GL32050@beryl \
    --to=denys@ti.com \
    --cc=d-senicic1@ti.com \
    --cc=j-stiffler@ti.com \
    --cc=meta-arago@arago-project.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.