<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom">
  <channel>
    <title>ASR on OHTLY Blog</title>
    <link>https://blog.ohtly.com/tags/asr/</link>
    <description>Recent content in ASR on OHTLY Blog</description>
    <generator>Hugo</generator>
    <language>zh-cn</language>
    <lastBuildDate>Mon, 25 May 2026 15:47:21 +0800</lastBuildDate>
    <atom:link href="https://blog.ohtly.com/tags/asr/index.xml" rel="self" type="application/rss+xml" />
    <item>
      <title>FunASR 视频字幕生成原型</title>
      <link>https://blog.ohtly.com/posts/2026-05-25-funasr-subtitle/</link>
      <pubDate>Mon, 25 May 2026 15:47:21 +0800</pubDate>
      <guid>https://blog.ohtly.com/posts/2026-05-25-funasr-subtitle/</guid>
      <description>&lt;h2 id=&#34;背景&#34;&gt;&#xA;  背景&#xA;  &lt;a class=&#34;heading-link&#34; href=&#34;#%e8%83%8c%e6%99%af&#34;&gt;&#xA;    &lt;i class=&#34;fa-solid fa-link&#34; aria-hidden=&#34;true&#34; title=&#34;链接到标题&#34;&gt;&lt;/i&gt;&#xA;    &lt;span class=&#34;sr-only&#34;&gt;链接到标题&lt;/span&gt;&#xA;  &lt;/a&gt;&#xA;&lt;/h2&gt;&#xA;&lt;p&gt;最近在研究从视频中自动生成字幕，选中了阿里云的 FunASR（Fun Audio Speech Recognition）模型。FunASR 支持端到端的语音识别和时间戳提取，理论上非常适合用于视频字幕生成。&lt;/p&gt;&#xA;&lt;h2 id=&#34;已知-bug&#34;&gt;&#xA;  已知 Bug&#xA;  &lt;a class=&#34;heading-link&#34; href=&#34;#%e5%b7%b2%e7%9f%a5-bug&#34;&gt;&#xA;    &lt;i class=&#34;fa-solid fa-link&#34; aria-hidden=&#34;true&#34; title=&#34;链接到标题&#34;&gt;&lt;/i&gt;&#xA;    &lt;span class=&#34;sr-only&#34;&gt;链接到标题&lt;/span&gt;&#xA;  &lt;/a&gt;&#xA;&lt;/h2&gt;&#xA;&lt;p&gt;FunASR v1.3.1（PyPI 最新版）配合 Fun-ASR-Nano 模型使用时存在两个官方未修复的 bug：&lt;/p&gt;&#xA;&lt;h3 id=&#34;bug-1-batch-decoding-is-not-implemented&#34;&gt;&#xA;  Bug 1: batch decoding is not implemented&#xA;  &lt;a class=&#34;heading-link&#34; href=&#34;#bug-1-batch-decoding-is-not-implemented&#34;&gt;&#xA;    &lt;i class=&#34;fa-solid fa-link&#34; aria-hidden=&#34;true&#34; title=&#34;链接到标题&#34;&gt;&lt;/i&gt;&#xA;    &lt;span class=&#34;sr-only&#34;&gt;链接到标题&lt;/span&gt;&#xA;  &lt;/a&gt;&#xA;&lt;/h3&gt;&#xA;&lt;p&gt;VAD 切段后 ASR 模型收到 batch 输入会抛出 &lt;code&gt;NotImplementedError&lt;/code&gt;。原因是 &lt;code&gt;auto_model.py&lt;/code&gt; 默认将 &lt;code&gt;batch_size&lt;/code&gt; 设为 300000，但模型不支持 batch 输入。&lt;/p&gt;&#xA;&lt;p&gt;&lt;strong&gt;修复&lt;/strong&gt;：传入 &lt;code&gt;batch_size_s=0&lt;/code&gt;&lt;/p&gt;&#xA;&lt;p&gt;详见：&lt;a href=&#34;https://github.com/modelscope/FunASR/issues/2273&#34;  class=&#34;external-link&#34; target=&#34;_blank&#34; rel=&#34;noopener&#34;&gt;#2273 - NotImplementedError: batch decoding is not implemented&lt;/a&gt;&lt;/p&gt;&#xA;&lt;h3 id=&#34;bug-2-keyerror-0&#34;&gt;&#xA;  Bug 2: KeyError: 0&#xA;  &lt;a class=&#34;heading-link&#34; href=&#34;#bug-2-keyerror-0&#34;&gt;&#xA;    &lt;i class=&#34;fa-solid fa-link&#34; aria-hidden=&#34;true&#34; title=&#34;链接到标题&#34;&gt;&lt;/i&gt;&#xA;    &lt;span class=&#34;sr-only&#34;&gt;链接到标题&lt;/span&gt;&#xA;  &lt;/a&gt;&#xA;&lt;/h3&gt;&#xA;&lt;p&gt;逐段处理后时间戳偏移时报 &lt;code&gt;KeyError: 0&lt;/code&gt;。原因是 Fun-ASR-Nano 返回的时间戳是 dict 格式 &lt;code&gt;{&amp;quot;start_time&amp;quot;: ..., &amp;quot;end_time&amp;quot;: ...}&lt;/code&gt;，而代码假设是 list 格式 &lt;code&gt;[start, end]&lt;/code&gt;。&lt;/p&gt;</description>
    </item>
  </channel>
</rss>
