From owner-svn-ports-head@freebsd.org Sat May 23 08:55:12 2020 Return-Path: Delivered-To: svn-ports-head@mailman.nyi.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2610:1c1:1:606c::19:1]) by mailman.nyi.freebsd.org (Postfix) with ESMTP id 7CFB22FC516; Sat, 23 May 2020 08:55:12 +0000 (UTC) (envelope-from yuri@FreeBSD.org) Received: from mxrelay.nyi.freebsd.org (mxrelay.nyi.freebsd.org [IPv6:2610:1c1:1:606c::19:3]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256 client-signature RSA-PSS (4096 bits) client-digest SHA256) (Client CN "mxrelay.nyi.freebsd.org", Issuer "Let's Encrypt Authority X3" (verified OK)) by mx1.freebsd.org (Postfix) with ESMTPS id 49Tccw1m7cz4Z4C; Sat, 23 May 2020 08:55:12 +0000 (UTC) (envelope-from yuri@FreeBSD.org) Received: from repo.freebsd.org (repo.freebsd.org [IPv6:2610:1c1:1:6068::e6a:0]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (Client did not present a certificate) by mxrelay.nyi.freebsd.org (Postfix) with ESMTPS id 33510D2E9; Sat, 23 May 2020 08:55:12 +0000 (UTC) (envelope-from yuri@FreeBSD.org) Received: from repo.freebsd.org ([127.0.1.37]) by repo.freebsd.org (8.15.2/8.15.2) with ESMTP id 04N8tC51010378; Sat, 23 May 2020 08:55:12 GMT (envelope-from yuri@FreeBSD.org) Received: (from yuri@localhost) by repo.freebsd.org (8.15.2/8.15.2/Submit) id 04N8tBR8010376; Sat, 23 May 2020 08:55:11 GMT (envelope-from yuri@FreeBSD.org) Message-Id: <202005230855.04N8tBR8010376@repo.freebsd.org> X-Authentication-Warning: repo.freebsd.org: yuri set sender to yuri@FreeBSD.org using -f From: Yuri Victorovich Date: Sat, 23 May 2020 08:55:11 +0000 (UTC) To: ports-committers@freebsd.org, svn-ports-all@freebsd.org, svn-ports-head@freebsd.org Subject: svn commit: r536274 - head/misc/mnn X-SVN-Group: ports-head X-SVN-Commit-Author: yuri X-SVN-Commit-Paths: head/misc/mnn X-SVN-Commit-Revision: 536274 X-SVN-Commit-Repository: ports MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-BeenThere: svn-ports-head@freebsd.org X-Mailman-Version: 2.1.33 Precedence: list List-Id: SVN commit messages for the ports tree for head List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 23 May 2020 08:55:12 -0000 Author: yuri Date: Sat May 23 08:55:11 2020 New Revision: 536274 URL: https://svnweb.freebsd.org/changeset/ports/536274 Log: misc/mnn: Add options for converter, training, tools, etc Modified: head/misc/mnn/Makefile head/misc/mnn/pkg-plist Modified: head/misc/mnn/Makefile ============================================================================== --- head/misc/mnn/Makefile Sat May 23 08:05:40 2020 (r536273) +++ head/misc/mnn/Makefile Sat May 23 08:55:11 2020 (r536274) @@ -2,6 +2,7 @@ PORTNAME= mnn DISTVERSION= 1.0.0 +PORTREVISION= 1 CATEGORIES= misc # machine-learning MAINTAINER= yuri@FreeBSD.org @@ -26,6 +27,26 @@ LDFLAGS+= -pthread CFLAGS+= -fPIC # workaround for https://github.com/alibaba/MNN/issues/553 CXXFLAGS+= -fPIC +OPTIONS_DEFINE= CONVERTER HARD_FP QUANTOOLS TOOLS TRAIN +OPTIONS_DEFAULT= CONVERTER HARD_FP QUANTOOLS TOOLS TRAIN +OPTIONS_SUB= yes + +CONVERTER_DESC= Build machine learning model converter +CONVERTER_CMAKE_BOOL= MNN_BUILD_CONVERTER +CONVERTER_LIB_DEPENDS= libprotobuf.so:devel/protobuf + +HARD_FP_DESC= Hard floating point numbers +HARD_FP_CMAKE_BOOL= MNN_BUILD_HARD + +QUANTOOLS_DESC= Build quantized tools +QUANTOOLS_CMAKE_BOOL= MNN_BUILD_QUANTOOLS + +TOOLS_DESC= Build tools +TOOLS_CMAKE_BOOL= MNN_BUILD_TOOLS + +TRAIN_DESC= Build MNN's training framework +TRAIN_CMAKE_BOOL= MNN_BUILD_TRAIN + .include .if ${ARCH} != amd64 && ${ARCH} != i386 @@ -35,6 +56,22 @@ CMAKE_ARGS+= -DMNN_USE_AVX:BOOL=OFF \ pre-build: # https://github.com/alibaba/MNN/issues/648 @cd ${WRKSRC}/schema && ./generate.sh + +do-install-CONVERTER-on: + ${INSTALL_PROGRAM} ${BUILD_WRKSRC}/MNNConvert ${STAGEDIR}${PREFIX}/bin + +do-install-QUANTOOLS-on: + ${INSTALL_PROGRAM} ${BUILD_WRKSRC}/quantized.out ${STAGEDIR}${PREFIX}/bin + +do-install-TOOLS-on: +.for f in MNNV2Basic.out mobilenetTest.out backendTest.out testModel.out testModelWithDescrisbe.out getPerformance.out checkInvalidValue.out timeProfile.out + ${INSTALL_PROGRAM} ${BUILD_WRKSRC}/${f} ${STAGEDIR}${PREFIX}/bin +.endfor + +do-install-TRAIN-on: +.for f in transformer.out train.out rawDataTransform.out dataTransformer.out runTrainDemo.out + ${INSTALL_PROGRAM} ${BUILD_WRKSRC}/${f} ${STAGEDIR}${PREFIX}/bin +.endfor do-test: @cd ${BUILD_WRKSRC} && \ Modified: head/misc/mnn/pkg-plist ============================================================================== --- head/misc/mnn/pkg-plist Sat May 23 08:05:40 2020 (r536273) +++ head/misc/mnn/pkg-plist Sat May 23 08:55:11 2020 (r536274) @@ -1,3 +1,18 @@ +%%CONVERTER%%bin/MNNConvert +%%QUANTOOLS%%bin/quantized.out +%%TOOLS%%bin/MNNV2Basic.out +%%TOOLS%%bin/backendTest.out +%%TOOLS%%bin/checkInvalidValue.out +%%TOOLS%%bin/getPerformance.out +%%TOOLS%%bin/mobilenetTest.out +%%TOOLS%%bin/testModel.out +%%TOOLS%%bin/testModelWithDescrisbe.out +%%TOOLS%%bin/timeProfile.out +%%TRAIN%%bin/dataTransformer.out +%%TRAIN%%bin/rawDataTransform.out +%%TRAIN%%bin/runTrainDemo.out +%%TRAIN%%bin/train.out +%%TRAIN%%bin/transformer.out include/MNN/AutoTime.hpp include/MNN/ErrorCode.hpp include/MNN/expr/Executor.hpp