#compdef ab-av1

autoload -U is-at-least

_ab-av1() {
    typeset -A opt_args
    typeset -a _arguments_options
    local ret=1

    if is-at-least 5.2; then
        _arguments_options=(-s -S -C)
    else
        _arguments_options=(-s -C)
    fi

    local context curcontext="$curcontext" state line
    _arguments "${_arguments_options[@]}" : \
'-h[Print help]' \
'--help[Print help]' \
'-V[Print version]' \
'--version[Print version]' \
":: :_ab-av1_commands" \
"*::: :->ab-av1" \
&& ret=0
    case $state in
    (ab-av1)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:ab-av1-command-$line[1]:"
        case $line[1] in
            (sample-encode)
_arguments "${_arguments_options[@]}" : \
'-e+[Encoder override. See https\://ffmpeg.org/ffmpeg-all.html#toc-Video-Encoders]:ENCODER:_default' \
'--encoder=[Encoder override. See https\://ffmpeg.org/ffmpeg-all.html#toc-Video-Encoders]:ENCODER:_default' \
'-i+[Input video file]:INPUT:_files' \
'--input=[Input video file]:INPUT:_files' \
'--vfilter=[Ffmpeg video filter applied to the input before encoding. E.g. --vfilter "scale=1280\:-1,fps=24"]:VFILTER:_default' \
'--pix-format=[Pixel format. svt-av1 default yuv420p10le]:PIX_FORMAT:(yuv420p yuv420p10le yuv444p10le)' \
'--preset=[Encoder preset (0-13). Higher presets means faster encodes, but with a quality tradeoff]:PRESET:_default' \
'--keyint=[Interval between keyframes. Can be specified as a number of frames, or a duration. E.g. "300" or "10s". Defaults to 10s if the input duration is over 3m]:KEYINT:_default' \
'--scd=[Svt-av1 scene change detection, inserts keyframes at scene changes. Defaults on if using default keyint & the input duration is over 3m. Otherwise off]:SCD:(true false)' \
'*--svt=[Additional svt-av1 arg(s). E.g. --svt mbr=2000 --svt film-grain=8]:SVT_ARGS:_default' \
'*--enc=[Additional ffmpeg encoder arg(s). E.g. \`--enc x265-params=lossless=1\` These are added as ffmpeg output file options]:ENC_ARGS:_default' \
'*--enc-input=[Additional ffmpeg input encoder arg(s). E.g. \`--enc-input r=1\` These are added as ffmpeg input file options]:ENC_INPUT_ARGS:_default' \
'--crf=[Encoder constant rate factor (1-63). Lower means better quality]:CRF:_default' \
'--samples=[Number of samples to use across the input video. Overrides --sample-every. More samples take longer but may provide a more accurate result]:SAMPLES:_default' \
'--sample-every=[Calculate number of samples by dividing the input duration by this value. So "12m" would mean with an input 25-36 minutes long, 3 samples would be used. More samples take longer but may provide a more accurate result]:SAMPLE_EVERY:_default' \
'--min-samples=[Minimum number of samples. So at least this many samples will be used]:MIN_SAMPLES:_default' \
'--sample-duration=[Duration of each sample]:SAMPLE_DURATION:_default' \
'--temp-dir=[Directory to store temporary sample data in. Defaults to using the input'\''s directory]:TEMP_DIR:_files -/' \
'--cache=[Enable sample-encode caching]:CACHE:(true false)' \
'--stdout-format=[Stdout message format \`human\` or \`json\`]:STDOUT_FORMAT:(human json)' \
'*--vmaf=[Additional vmaf arg(s). E.g. --vmaf n_threads=8 --vmaf n_subsample=4]:VMAF_ARGS:_default' \
'--vmaf-scale=[Video resolution scale to use in VMAF analysis. If set, video streams will be bicubic scaled to this during VMAF analysis. \`auto\` (default) automatically sets based on the model and input video resolution. \`none\` disables any scaling. \`WxH\` format may be used to specify custom scaling, e.g. \`1920x1080\`]:VMAF_SCALE:_default' \
'--vmaf-fps=[Frame rate override used to analyse both reference & distorted videos. Maps to ffmpeg \`-r\` input arg]:VMAF_FPS:_default' \
'--reference-vfilter=[Ffmpeg video filter applied to the VMAF/XPSNR reference before analysis. E.g. --reference-vfilter "scale=1280\:-1,fps=24"]:REFERENCE_VFILTER:_default' \
'--xpsnr-fps=[Frame rate override used to analyse both reference & distorted videos. Maps to ffmpeg \`-r\` input arg]:XPSNR_FPS:_default' \
'--keep[Keep temporary files after exiting]' \
'--xpsnr[Calculate a XPSNR score instead of VMAF]' \
'-h[Print help (see more with '\''--help'\'')]' \
'--help[Print help (see more with '\''--help'\'')]' \
&& ret=0
;;
(vmaf)
_arguments "${_arguments_options[@]}" : \
'--reference=[Reference video file]:REFERENCE:_files' \
'--distorted=[Re-encoded/distorted video file]:DISTORTED:_files' \
'*--vmaf=[Additional vmaf arg(s). E.g. --vmaf n_threads=8 --vmaf n_subsample=4]:VMAF_ARGS:_default' \
'--vmaf-scale=[Video resolution scale to use in VMAF analysis. If set, video streams will be bicubic scaled to this during VMAF analysis. \`auto\` (default) automatically sets based on the model and input video resolution. \`none\` disables any scaling. \`WxH\` format may be used to specify custom scaling, e.g. \`1920x1080\`]:VMAF_SCALE:_default' \
'--vmaf-fps=[Frame rate override used to analyse both reference & distorted videos. Maps to ffmpeg \`-r\` input arg]:VMAF_FPS:_default' \
'--reference-vfilter=[Ffmpeg video filter applied to the VMAF/XPSNR reference before analysis. E.g. --reference-vfilter "scale=1280\:-1,fps=24"]:REFERENCE_VFILTER:_default' \
'-h[Print help (see more with '\''--help'\'')]' \
'--help[Print help (see more with '\''--help'\'')]' \
&& ret=0
;;
(xpsnr)
_arguments "${_arguments_options[@]}" : \
'--reference=[Reference video file]:REFERENCE:_files' \
'--distorted=[Re-encoded/distorted video file]:DISTORTED:_files' \
'--reference-vfilter=[Ffmpeg video filter applied to the VMAF/XPSNR reference before analysis. E.g. --reference-vfilter "scale=1280\:-1,fps=24"]:REFERENCE_VFILTER:_default' \
'--xpsnr-fps=[Frame rate override used to analyse both reference & distorted videos. Maps to ffmpeg \`-r\` input arg]:XPSNR_FPS:_default' \
'-h[Print help (see more with '\''--help'\'')]' \
'--help[Print help (see more with '\''--help'\'')]' \
&& ret=0
;;
(encode)
_arguments "${_arguments_options[@]}" : \
'-e+[Encoder override. See https\://ffmpeg.org/ffmpeg-all.html#toc-Video-Encoders]:ENCODER:_default' \
'--encoder=[Encoder override. See https\://ffmpeg.org/ffmpeg-all.html#toc-Video-Encoders]:ENCODER:_default' \
'-i+[Input video file]:INPUT:_files' \
'--input=[Input video file]:INPUT:_files' \
'--vfilter=[Ffmpeg video filter applied to the input before encoding. E.g. --vfilter "scale=1280\:-1,fps=24"]:VFILTER:_default' \
'--pix-format=[Pixel format. svt-av1 default yuv420p10le]:PIX_FORMAT:(yuv420p yuv420p10le yuv444p10le)' \
'--preset=[Encoder preset (0-13). Higher presets means faster encodes, but with a quality tradeoff]:PRESET:_default' \
'--keyint=[Interval between keyframes. Can be specified as a number of frames, or a duration. E.g. "300" or "10s". Defaults to 10s if the input duration is over 3m]:KEYINT:_default' \
'--scd=[Svt-av1 scene change detection, inserts keyframes at scene changes. Defaults on if using default keyint & the input duration is over 3m. Otherwise off]:SCD:(true false)' \
'*--svt=[Additional svt-av1 arg(s). E.g. --svt mbr=2000 --svt film-grain=8]:SVT_ARGS:_default' \
'*--enc=[Additional ffmpeg encoder arg(s). E.g. \`--enc x265-params=lossless=1\` These are added as ffmpeg output file options]:ENC_ARGS:_default' \
'*--enc-input=[Additional ffmpeg input encoder arg(s). E.g. \`--enc-input r=1\` These are added as ffmpeg input file options]:ENC_INPUT_ARGS:_default' \
'--crf=[Encoder constant rate factor (1-63). Lower means better quality]:CRF:_default' \
'-o+[Output file, by default the same as input with \`.av1\` before the extension]:OUTPUT:_files' \
'--output=[Output file, by default the same as input with \`.av1\` before the extension]:OUTPUT:_files' \
'--acodec=[Set the output ffmpeg audio codec. By default '\''copy'\'' is used. Otherwise, if re-encoding is necessary, '\''libopus'\'' is default]:AUDIO_CODEC:_default' \
'--downmix-to-stereo[Downmix input audio streams to stereo if input streams use greater than 3 channels]' \
'--video-only[Only process the main video stream, drop all other streams]' \
'-h[Print help (see more with '\''--help'\'')]' \
'--help[Print help (see more with '\''--help'\'')]' \
&& ret=0
;;
(crf-search)
_arguments "${_arguments_options[@]}" : \
'-e+[Encoder override. See https\://ffmpeg.org/ffmpeg-all.html#toc-Video-Encoders]:ENCODER:_default' \
'--encoder=[Encoder override. See https\://ffmpeg.org/ffmpeg-all.html#toc-Video-Encoders]:ENCODER:_default' \
'-i+[Input video file]:INPUT:_files' \
'--input=[Input video file]:INPUT:_files' \
'--vfilter=[Ffmpeg video filter applied to the input before encoding. E.g. --vfilter "scale=1280\:-1,fps=24"]:VFILTER:_default' \
'--pix-format=[Pixel format. svt-av1 default yuv420p10le]:PIX_FORMAT:(yuv420p yuv420p10le yuv444p10le)' \
'--preset=[Encoder preset (0-13). Higher presets means faster encodes, but with a quality tradeoff]:PRESET:_default' \
'--keyint=[Interval between keyframes. Can be specified as a number of frames, or a duration. E.g. "300" or "10s". Defaults to 10s if the input duration is over 3m]:KEYINT:_default' \
'--scd=[Svt-av1 scene change detection, inserts keyframes at scene changes. Defaults on if using default keyint & the input duration is over 3m. Otherwise off]:SCD:(true false)' \
'*--svt=[Additional svt-av1 arg(s). E.g. --svt mbr=2000 --svt film-grain=8]:SVT_ARGS:_default' \
'*--enc=[Additional ffmpeg encoder arg(s). E.g. \`--enc x265-params=lossless=1\` These are added as ffmpeg output file options]:ENC_ARGS:_default' \
'*--enc-input=[Additional ffmpeg input encoder arg(s). E.g. \`--enc-input r=1\` These are added as ffmpeg input file options]:ENC_INPUT_ARGS:_default' \
'--min-vmaf=[Desired min VMAF score to deliver]:MIN_VMAF:_default' \
'--min-xpsnr=[Desired min XPSNR score to deliver]:MIN_XPSNR:_default' \
'--max-encoded-percent=[Maximum desired encoded size percentage of the input size]:MAX_ENCODED_PERCENT:_default' \
'--min-crf=[Minimum (highest quality) crf value to try]:MIN_CRF:_default' \
'--max-crf=[Maximum (lowest quality) crf value to try]:MAX_CRF:_default' \
'--crf-increment=[Constant rate factor search increment precision]:CRF_INCREMENT:_default' \
'--cache=[Enable sample-encode caching]:CACHE:(true false)' \
'--samples=[Number of samples to use across the input video. Overrides --sample-every. More samples take longer but may provide a more accurate result]:SAMPLES:_default' \
'--sample-every=[Calculate number of samples by dividing the input duration by this value. So "12m" would mean with an input 25-36 minutes long, 3 samples would be used. More samples take longer but may provide a more accurate result]:SAMPLE_EVERY:_default' \
'--min-samples=[Minimum number of samples. So at least this many samples will be used]:MIN_SAMPLES:_default' \
'--sample-duration=[Duration of each sample]:SAMPLE_DURATION:_default' \
'--temp-dir=[Directory to store temporary sample data in. Defaults to using the input'\''s directory]:TEMP_DIR:_files -/' \
'*--vmaf=[Additional vmaf arg(s). E.g. --vmaf n_threads=8 --vmaf n_subsample=4]:VMAF_ARGS:_default' \
'--vmaf-scale=[Video resolution scale to use in VMAF analysis. If set, video streams will be bicubic scaled to this during VMAF analysis. \`auto\` (default) automatically sets based on the model and input video resolution. \`none\` disables any scaling. \`WxH\` format may be used to specify custom scaling, e.g. \`1920x1080\`]:VMAF_SCALE:_default' \
'--vmaf-fps=[Frame rate override used to analyse both reference & distorted videos. Maps to ffmpeg \`-r\` input arg]:VMAF_FPS:_default' \
'--reference-vfilter=[Ffmpeg video filter applied to the VMAF/XPSNR reference before analysis. E.g. --reference-vfilter "scale=1280\:-1,fps=24"]:REFERENCE_VFILTER:_default' \
'--xpsnr-fps=[Frame rate override used to analyse both reference & distorted videos. Maps to ffmpeg \`-r\` input arg]:XPSNR_FPS:_default' \
'--thorough[Keep searching until a crf is found no more than min_vmaf+0.05 or all possibilities have been attempted]' \
'--keep[Keep temporary files after exiting]' \
'*-v[Increase logging verbosity]' \
'*--verbose[Increase logging verbosity]' \
'(-v --verbose)*-q[Decrease logging verbosity]' \
'(-v --verbose)*--quiet[Decrease logging verbosity]' \
'-h[Print help (see more with '\''--help'\'')]' \
'--help[Print help (see more with '\''--help'\'')]' \
&& ret=0
;;
(auto-encode)
_arguments "${_arguments_options[@]}" : \
'-e+[Encoder override. See https\://ffmpeg.org/ffmpeg-all.html#toc-Video-Encoders]:ENCODER:_default' \
'--encoder=[Encoder override. See https\://ffmpeg.org/ffmpeg-all.html#toc-Video-Encoders]:ENCODER:_default' \
'-i+[Input video file]:INPUT:_files' \
'--input=[Input video file]:INPUT:_files' \
'--vfilter=[Ffmpeg video filter applied to the input before encoding. E.g. --vfilter "scale=1280\:-1,fps=24"]:VFILTER:_default' \
'--pix-format=[Pixel format. svt-av1 default yuv420p10le]:PIX_FORMAT:(yuv420p yuv420p10le yuv444p10le)' \
'--preset=[Encoder preset (0-13). Higher presets means faster encodes, but with a quality tradeoff]:PRESET:_default' \
'--keyint=[Interval between keyframes. Can be specified as a number of frames, or a duration. E.g. "300" or "10s". Defaults to 10s if the input duration is over 3m]:KEYINT:_default' \
'--scd=[Svt-av1 scene change detection, inserts keyframes at scene changes. Defaults on if using default keyint & the input duration is over 3m. Otherwise off]:SCD:(true false)' \
'*--svt=[Additional svt-av1 arg(s). E.g. --svt mbr=2000 --svt film-grain=8]:SVT_ARGS:_default' \
'*--enc=[Additional ffmpeg encoder arg(s). E.g. \`--enc x265-params=lossless=1\` These are added as ffmpeg output file options]:ENC_ARGS:_default' \
'*--enc-input=[Additional ffmpeg input encoder arg(s). E.g. \`--enc-input r=1\` These are added as ffmpeg input file options]:ENC_INPUT_ARGS:_default' \
'--min-vmaf=[Desired min VMAF score to deliver]:MIN_VMAF:_default' \
'--min-xpsnr=[Desired min XPSNR score to deliver]:MIN_XPSNR:_default' \
'--max-encoded-percent=[Maximum desired encoded size percentage of the input size]:MAX_ENCODED_PERCENT:_default' \
'--min-crf=[Minimum (highest quality) crf value to try]:MIN_CRF:_default' \
'--max-crf=[Maximum (lowest quality) crf value to try]:MAX_CRF:_default' \
'--crf-increment=[Constant rate factor search increment precision]:CRF_INCREMENT:_default' \
'--cache=[Enable sample-encode caching]:CACHE:(true false)' \
'--samples=[Number of samples to use across the input video. Overrides --sample-every. More samples take longer but may provide a more accurate result]:SAMPLES:_default' \
'--sample-every=[Calculate number of samples by dividing the input duration by this value. So "12m" would mean with an input 25-36 minutes long, 3 samples would be used. More samples take longer but may provide a more accurate result]:SAMPLE_EVERY:_default' \
'--min-samples=[Minimum number of samples. So at least this many samples will be used]:MIN_SAMPLES:_default' \
'--sample-duration=[Duration of each sample]:SAMPLE_DURATION:_default' \
'--temp-dir=[Directory to store temporary sample data in. Defaults to using the input'\''s directory]:TEMP_DIR:_files -/' \
'*--vmaf=[Additional vmaf arg(s). E.g. --vmaf n_threads=8 --vmaf n_subsample=4]:VMAF_ARGS:_default' \
'--vmaf-scale=[Video resolution scale to use in VMAF analysis. If set, video streams will be bicubic scaled to this during VMAF analysis. \`auto\` (default) automatically sets based on the model and input video resolution. \`none\` disables any scaling. \`WxH\` format may be used to specify custom scaling, e.g. \`1920x1080\`]:VMAF_SCALE:_default' \
'--vmaf-fps=[Frame rate override used to analyse both reference & distorted videos. Maps to ffmpeg \`-r\` input arg]:VMAF_FPS:_default' \
'--reference-vfilter=[Ffmpeg video filter applied to the VMAF/XPSNR reference before analysis. E.g. --reference-vfilter "scale=1280\:-1,fps=24"]:REFERENCE_VFILTER:_default' \
'--xpsnr-fps=[Frame rate override used to analyse both reference & distorted videos. Maps to ffmpeg \`-r\` input arg]:XPSNR_FPS:_default' \
'-o+[Output file, by default the same as input with \`.av1\` before the extension]:OUTPUT:_files' \
'--output=[Output file, by default the same as input with \`.av1\` before the extension]:OUTPUT:_files' \
'--acodec=[Set the output ffmpeg audio codec. By default '\''copy'\'' is used. Otherwise, if re-encoding is necessary, '\''libopus'\'' is default]:AUDIO_CODEC:_default' \
'--thorough[Keep searching until a crf is found no more than min_vmaf+0.05 or all possibilities have been attempted]' \
'--keep[Keep temporary files after exiting]' \
'*-v[Increase logging verbosity]' \
'*--verbose[Increase logging verbosity]' \
'(-v --verbose)*-q[Decrease logging verbosity]' \
'(-v --verbose)*--quiet[Decrease logging verbosity]' \
'--downmix-to-stereo[Downmix input audio streams to stereo if input streams use greater than 3 channels]' \
'--video-only[Only process the main video stream, drop all other streams]' \
'-h[Print help (see more with '\''--help'\'')]' \
'--help[Print help (see more with '\''--help'\'')]' \
&& ret=0
;;
(print-completions)
_arguments "${_arguments_options[@]}" : \
'-h[Print help]' \
'--help[Print help]' \
'::shell -- Shell:(bash elvish fish powershell zsh)' \
&& ret=0
;;
(help)
_arguments "${_arguments_options[@]}" : \
":: :_ab-av1__help_commands" \
"*::: :->help" \
&& ret=0

    case $state in
    (help)
        words=($line[1] "${words[@]}")
        (( CURRENT += 1 ))
        curcontext="${curcontext%:*:*}:ab-av1-help-command-$line[1]:"
        case $line[1] in
            (sample-encode)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(vmaf)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(xpsnr)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(encode)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(crf-search)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(auto-encode)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(print-completions)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
(help)
_arguments "${_arguments_options[@]}" : \
&& ret=0
;;
        esac
    ;;
esac
;;
        esac
    ;;
esac
}

(( $+functions[_ab-av1_commands] )) ||
_ab-av1_commands() {
    local commands; commands=(
'sample-encode:Encode & analyse input samples to predict how a full encode would go. This is much quicker than a full encode/vmaf run.' \
'vmaf:Full VMAF score calculation, distorted file vs reference file. Works with videos and images.' \
'xpsnr:Full XPSNR score calculation, distorted file vs reference file. Works with videos and images.' \
'encode:Invoke ffmpeg to encode a video or image' \
'crf-search:Interpolated binary search using sample-encode to find the best crf value delivering min-vmaf & max-encoded-percent.' \
'auto-encode:Automatically determine the best crf to deliver the min-vmaf and use it to encode a video or image.' \
'print-completions:Print shell completions' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'ab-av1 commands' commands "$@"
}
(( $+functions[_ab-av1__auto-encode_commands] )) ||
_ab-av1__auto-encode_commands() {
    local commands; commands=()
    _describe -t commands 'ab-av1 auto-encode commands' commands "$@"
}
(( $+functions[_ab-av1__crf-search_commands] )) ||
_ab-av1__crf-search_commands() {
    local commands; commands=()
    _describe -t commands 'ab-av1 crf-search commands' commands "$@"
}
(( $+functions[_ab-av1__encode_commands] )) ||
_ab-av1__encode_commands() {
    local commands; commands=()
    _describe -t commands 'ab-av1 encode commands' commands "$@"
}
(( $+functions[_ab-av1__help_commands] )) ||
_ab-av1__help_commands() {
    local commands; commands=(
'sample-encode:Encode & analyse input samples to predict how a full encode would go. This is much quicker than a full encode/vmaf run.' \
'vmaf:Full VMAF score calculation, distorted file vs reference file. Works with videos and images.' \
'xpsnr:Full XPSNR score calculation, distorted file vs reference file. Works with videos and images.' \
'encode:Invoke ffmpeg to encode a video or image' \
'crf-search:Interpolated binary search using sample-encode to find the best crf value delivering min-vmaf & max-encoded-percent.' \
'auto-encode:Automatically determine the best crf to deliver the min-vmaf and use it to encode a video or image.' \
'print-completions:Print shell completions' \
'help:Print this message or the help of the given subcommand(s)' \
    )
    _describe -t commands 'ab-av1 help commands' commands "$@"
}
(( $+functions[_ab-av1__help__auto-encode_commands] )) ||
_ab-av1__help__auto-encode_commands() {
    local commands; commands=()
    _describe -t commands 'ab-av1 help auto-encode commands' commands "$@"
}
(( $+functions[_ab-av1__help__crf-search_commands] )) ||
_ab-av1__help__crf-search_commands() {
    local commands; commands=()
    _describe -t commands 'ab-av1 help crf-search commands' commands "$@"
}
(( $+functions[_ab-av1__help__encode_commands] )) ||
_ab-av1__help__encode_commands() {
    local commands; commands=()
    _describe -t commands 'ab-av1 help encode commands' commands "$@"
}
(( $+functions[_ab-av1__help__help_commands] )) ||
_ab-av1__help__help_commands() {
    local commands; commands=()
    _describe -t commands 'ab-av1 help help commands' commands "$@"
}
(( $+functions[_ab-av1__help__print-completions_commands] )) ||
_ab-av1__help__print-completions_commands() {
    local commands; commands=()
    _describe -t commands 'ab-av1 help print-completions commands' commands "$@"
}
(( $+functions[_ab-av1__help__sample-encode_commands] )) ||
_ab-av1__help__sample-encode_commands() {
    local commands; commands=()
    _describe -t commands 'ab-av1 help sample-encode commands' commands "$@"
}
(( $+functions[_ab-av1__help__vmaf_commands] )) ||
_ab-av1__help__vmaf_commands() {
    local commands; commands=()
    _describe -t commands 'ab-av1 help vmaf commands' commands "$@"
}
(( $+functions[_ab-av1__help__xpsnr_commands] )) ||
_ab-av1__help__xpsnr_commands() {
    local commands; commands=()
    _describe -t commands 'ab-av1 help xpsnr commands' commands "$@"
}
(( $+functions[_ab-av1__print-completions_commands] )) ||
_ab-av1__print-completions_commands() {
    local commands; commands=()
    _describe -t commands 'ab-av1 print-completions commands' commands "$@"
}
(( $+functions[_ab-av1__sample-encode_commands] )) ||
_ab-av1__sample-encode_commands() {
    local commands; commands=()
    _describe -t commands 'ab-av1 sample-encode commands' commands "$@"
}
(( $+functions[_ab-av1__vmaf_commands] )) ||
_ab-av1__vmaf_commands() {
    local commands; commands=()
    _describe -t commands 'ab-av1 vmaf commands' commands "$@"
}
(( $+functions[_ab-av1__xpsnr_commands] )) ||
_ab-av1__xpsnr_commands() {
    local commands; commands=()
    _describe -t commands 'ab-av1 xpsnr commands' commands "$@"
}

if [ "$funcstack[1]" = "_ab-av1" ]; then
    _ab-av1 "$@"
else
    compdef _ab-av1 ab-av1
fi
