From patchwork Thu Apr 29 12:46:10 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Lance Wang X-Patchwork-Id: 27471 Delivered-To: ffmpegpatchwork2@gmail.com Received: by 2002:a05:6a11:4023:0:0:0:0 with SMTP id ky35csp1430319pxb; Thu, 29 Apr 2021 05:46:28 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx8DsCgHDn9K2LvAzu1imLBz+RHvQ594UZbjy8fhMuJpVwr3GzanJk1rEQ4sBVoAYxh23xJ X-Received: by 2002:aa7:c1d6:: with SMTP id d22mr9824292edp.180.1619700388508; Thu, 29 Apr 2021 05:46:28 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1619700388; cv=none; d=google.com; s=arc-20160816; b=Ko+MQbdGciNzSayp+jO5rB0rAlMJriBKBZpMocBkt+VW5snTJbJ4eUQ4D8w9gpPBO8 BkcaKgs18jlv+1QMqhBvWy68y9poldc/qn9qhENPfuYCMa7ZodqX5SH/GofDO6dAKPtQ yvTeDnbX3whY2mNAoim1Pz3dwnD+SHQUfV/xK69tKmbpISYQ2eXs1RFMAmn+3K1xD9iA BCf1cJEth7hBLM0QMpXkmqLrg76qDrc4Lzo2BjZyO1klBtCu0z00ANQRmoArLGqtYmo0 /WTAwrdWVF7DPI2n6UhBFyInNl3LvTjwhmD9+FL8TtmlLyca8TItdzPJ83sg745rxHKR /g6Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:mime-version:cc:reply-to :list-subscribe:list-help:list-post:list-archive:list-unsubscribe :list-id:precedence:subject:references:in-reply-to:message-id:date :to:from:dkim-signature:delivered-to; bh=ukzsrSmzhjLS/Jcm/3AKXNHPyDCx95T4UYrhK4lzBA8=; b=ygB2Z02Y6hiiCWiw2tsiGLyJPLZqj4InUDubHT0HtS5DgLesBNXHOQqIUMEb1VewpR yGnsyWIjGGXbz9H4iboCXqZKkhUs3v0t2OT/S7tBI03A3nWFZ89oJA7L7HH7N7MYFDDC IrDLu04/PT1R2ZwKXz+P87eoSJmMQmg4hE7uI2Ypw3nVxYZipCnBEtwduZN+bDs0/8+Q 2THN2t9mxQOLDPcTvt6iY18QeeSTBu8IJs2NbDERIdxY8zg3maUsGzOj5c4F3lxIDc8w DXQufCtm0a471bt5ByPevxPMSR6uzHqkDYugVfVbC1Kw8lc+yynj/LN3EGkgsBPpqtx4 iWRw== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=jB6HzPMT; spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from ffbox0-bg.mplayerhq.hu (ffbox0-bg.ffmpeg.org. [79.124.17.100]) by mx.google.com with ESMTP id x7si2793143edd.140.2021.04.29.05.46.27; Thu, 29 Apr 2021 05:46:28 -0700 (PDT) Received-SPF: pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) client-ip=79.124.17.100; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@gmail.com header.s=20161025 header.b=jB6HzPMT; spf=pass (google.com: domain of ffmpeg-devel-bounces@ffmpeg.org designates 79.124.17.100 as permitted sender) smtp.mailfrom=ffmpeg-devel-bounces@ffmpeg.org; dmarc=fail (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from [127.0.1.1] (localhost [127.0.0.1]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTP id A3BFC68A094; Thu, 29 Apr 2021 15:46:23 +0300 (EEST) X-Original-To: ffmpeg-devel@ffmpeg.org Delivered-To: ffmpeg-devel@ffmpeg.org Received: from mail-pj1-f53.google.com (mail-pj1-f53.google.com [209.85.216.53]) by ffbox0-bg.mplayerhq.hu (Postfix) with ESMTPS id 7FFD7688068 for ; Thu, 29 Apr 2021 15:46:16 +0300 (EEST) Received: by mail-pj1-f53.google.com with SMTP id f11-20020a17090a638bb02901524d3a3d48so10808590pjj.3 for ; Thu, 29 Apr 2021 05:46:16 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=peuipjw7zfS7QTw15TkORYnGLmM2OA/6O2s5PrUoVjE=; b=jB6HzPMTEC+Z1xKk/LdxK5LJO5mVrP22TL5gkFOxRG1mW6LJ+7Zd6c5tHBSOjycMe7 /484j9rqRjYO5fsjQ/KBn/E1eMtdMntrnCFG1yhNr+w/o/XUR/RbQjw0oIWl4Bq0RaGq K3Ad/iFOWSfayhK6BUXOsJ9qB7ODagIdoKQTekUn8YV1reV/nTLmliQ2WitnrF33Z5lB 2bswba82Bsnc8mBU6DjRNMvUO4jlZ+8TSZhL9IOOKgsOauJLNqLtlwmeAHjLh/g57qS1 DqWp7n/TvT7xKfi3TJyLvKJL1RbMx2wU8uQ+EuHaYbC+ugMbCjj9kgBoiEfAWxGKdXpZ 4YQg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=peuipjw7zfS7QTw15TkORYnGLmM2OA/6O2s5PrUoVjE=; b=O2hswCU9B+G15ffC/l7aoTKReir5VrkhUdZ1aifwXRi0eCzIQTwdV//O28YN85yEzn n6t2AhvKAJ3F94P4Hd9yvZBiHQNW7TWkCcoPtl8xX0B8iroWEg/C6uAi6O5+d5Rdvpr4 QIHrVTqXFq3lsTBG+rUTHwL1R/MSlLGu6sD8e1ZxwfU67I5mH2tJQtVS1mI/R5gwZy07 aboMmLipuf1LqEq3MbWYxMvVcjLQqbCXE3/+ewYZ3yb4ZDq54TG65S174Qx3xVzb7MZy mo8FgS/RQPOGe7ZHv0u3mmFMYFXimSP3V107+B1SzvviZPOJMvvB2RLboscTSiMtA3ZF lMhA== X-Gm-Message-State: AOAM530VM8L1tJnpncHSUkD081La7cs72htauDOXjZ20zf4MnAbPT4BL 1ZNCwh8s8OOivzvffWjGp2tXJlHaPhk= X-Received: by 2002:a17:90a:1990:: with SMTP id 16mr9318283pji.172.1619700374627; Thu, 29 Apr 2021 05:46:14 -0700 (PDT) Received: from vpn2.localdomain ([161.117.202.209]) by smtp.gmail.com with ESMTPSA id a185sm2440468pfd.70.2021.04.29.05.46.13 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Thu, 29 Apr 2021 05:46:14 -0700 (PDT) From: lance.lmwang@gmail.com To: ffmpeg-devel@ffmpeg.org Date: Thu, 29 Apr 2021 20:46:10 +0800 Message-Id: <1619700370-8970-1-git-send-email-lance.lmwang@gmail.com> X-Mailer: git-send-email 1.8.3.1 In-Reply-To: <1619434136-17760-1-git-send-email-lance.lmwang@gmail.com> References: <1619434136-17760-1-git-send-email-lance.lmwang@gmail.com> Subject: [FFmpeg-devel] [PATCH v4] doc/filters: Documentation to add sess_config option for tensorflow backend X-BeenThere: ffmpeg-devel@ffmpeg.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: FFmpeg development discussions and patches List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: FFmpeg development discussions and patches Cc: Limin Wang MIME-Version: 1.0 Errors-To: ffmpeg-devel-bounces@ffmpeg.org Sender: "ffmpeg-devel" X-TUID: 3bVvGS3opMzG From: Limin Wang Signed-off-by: Limin Wang --- doc/filters.texi | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/doc/filters.texi b/doc/filters.texi index e99d70a..4af5b72 100644 --- a/doc/filters.texi +++ b/doc/filters.texi @@ -10214,6 +10214,12 @@ Set the input name of the dnn network. @item output Set the output name of the dnn network. +@item backend_configs +Set the configs to be passed into backend + +For tensorflow backend, you can set its configs with @option{sess_config} options, +please use tools/python/tf_sess_config.py to get the configs of TensorFlow backend for your system. + @item async use DNN async execution if set (default: set), roll back to sync execution if the backend does not support async. @@ -10242,9 +10248,10 @@ Handle the Y channel with srcnn.pb (see @ref{sr} filter) for frame with yuv420p @end example @item -Handle the Y channel with espcn.pb (see @ref{sr} filter), which changes frame size, for format yuv420p (planar YUV formats supported): +Handle the Y channel with espcn.pb (see @ref{sr} filter), which changes frame size, for format yuv420p (planar YUV formats supported), +please use tools/python/tf_sess_config.py to get the configs for your system. @example -./ffmpeg -i 480p.jpg -vf format=yuv420p,dnn_processing=dnn_backend=tensorflow:model=espcn.pb:input=x:output=y -y tmp.espcn.jpg +./ffmpeg -i 480p.jpg -vf format=yuv420p,dnn_processing=dnn_backend=tensorflow:model=espcn.pb:input=x:output=y:backend_configs=sess_config=0x10022805320e09cdccccccccccec3f20012a01303801 -y tmp.espcn.jpg @end example @end itemize