Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel
 help / color / mirror / Atom feed
From: "Guo, Yejun" <yejun.guo-at-intel.com@ffmpeg.org>
To: FFmpeg development discussions and patches <ffmpeg-devel@ffmpeg.org>
Subject: Re: [FFmpeg-devel] [PATCH v2 FFmpeg 11/20] libavfilter/dnn_filter_common: dnn execute functions for CLIP and CLAP
Date: Mon, 12 May 2025 10:11:37 +0000
Message-ID: <PH7PR11MB5957561674011A5844996F71F197A@PH7PR11MB5957.namprd11.prod.outlook.com> (raw)
In-Reply-To: <003f01db91f6$36603a60$a320af20$@gmail.com>



> -----Original Message-----
> From: ffmpeg-devel <ffmpeg-devel-bounces@ffmpeg.org> On Behalf Of
> m.kaindl0208@gmail.com
> Sent: Tuesday, March 11, 2025 3:54 AM
> To: ffmpeg-devel@ffmpeg.org
> Subject: [FFmpeg-devel] [PATCH v2 FFmpeg 11/20]
> libavfilter/dnn_filter_common: dnn execute functions for CLIP and CLAP
> 
> Signed-off-by: MaximilianKaindl <m.kaindl0208@gmail.com>
> ---
>  libavfilter/dnn_filter_common.c | 81 +++++++++++++++++++++++----------
>  libavfilter/dnn_filter_common.h | 34 +++++++-------
>  2 files changed, 76 insertions(+), 39 deletions(-)
> 
> diff --git a/libavfilter/dnn_filter_common.c b/libavfilter/dnn_filter_common.c
> index 899e869cca..f3117748ae 100644
> --- a/libavfilter/dnn_filter_common.c
> +++ b/libavfilter/dnn_filter_common.c
> +int ff_dnn_execute_model_clip(DnnContext *ctx, AVFrame *in_frame,
> AVFrame *out_frame, const char **labels, int label_count, const char*
> tokenizer_path, char *target)
> +{
> +    DNNExecZeroShotClassificationParams class_params = {
> +        {
> +            .input_name     = ctx->model_inputname,
> +            .output_names   = (const char **)ctx->model_outputnames,
> +            .nb_output      = ctx->nb_outputs,
> +            .in_frame       = in_frame,
> +            .out_frame      = out_frame,
> +        },
> +        .labels = labels,
> +        .label_count = label_count,
> +        .tokenizer_path = tokenizer_path,

Why we need tokenizer_path to execute model since it is already initialized in load_model_with_tokenizer from patch 10.

> +        .target = target,
> +    };
> +    return (ctx->dnn_module->execute_model)(ctx->model,
> &class_params.base);
> +}
> +

_______________________________________________
ffmpeg-devel mailing list
ffmpeg-devel@ffmpeg.org
https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

To unsubscribe, visit link above, or email
ffmpeg-devel-request@ffmpeg.org with subject "unsubscribe".

      parent reply	other threads:[~2025-05-12 10:11 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-03-10 19:54 m.kaindl0208
2025-05-12 10:08 ` Guo, Yejun
2025-05-12 10:11 ` Guo, Yejun [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=PH7PR11MB5957561674011A5844996F71F197A@PH7PR11MB5957.namprd11.prod.outlook.com \
    --to=yejun.guo-at-intel.com@ffmpeg.org \
    --cc=ffmpeg-devel@ffmpeg.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

Git Inbox Mirror of the ffmpeg-devel mailing list - see https://ffmpeg.org/mailman/listinfo/ffmpeg-devel

This inbox may be cloned and mirrored by anyone:

	git clone --mirror https://master.gitmailbox.com/ffmpegdev/0 ffmpegdev/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 ffmpegdev ffmpegdev/ https://master.gitmailbox.com/ffmpegdev \
		ffmpegdev@gitmailbox.com
	public-inbox-index ffmpegdev

Example config snippet for mirrors.


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git