import{_ as t,c as s,o as i,ag as e}from"./chunks/framework.B90TcSfW.js";const k=JSON.parse('{"title":"基准测试","description":"","frontmatter":{},"headers":[],"relativePath":"zh/benchmark.md","filePath":"zh/benchmark.md","lastUpdated":null}'),l={name:"zh/benchmark.md"};function n(r,a,h,d,p,o){return i(),s("div",null,a[0]||(a[0]=[e(`<h1 id="基准测试" tabindex="-1">基准测试 <a class="header-anchor" href="#基准测试" aria-label="Permalink to &quot;基准测试&quot;">​</a></h1><p>Spectral-Hub 的基准测试和评估指标。</p><h2 id="支持的数据集" tabindex="-1">支持的数据集 <a class="header-anchor" href="#支持的数据集" aria-label="Permalink to &quot;支持的数据集&quot;">​</a></h2><ul><li><strong>IR Spectra</strong>: 红外光谱数据</li><li><strong>Raman Spectra</strong>: 拉曼光谱数据</li><li><strong>NMR Spectra</strong>: 核磁共振数据</li></ul><h2 id="评估指标" tabindex="-1">评估指标 <a class="header-anchor" href="#评估指标" aria-label="Permalink to &quot;评估指标&quot;">​</a></h2><ul><li>准确率 (Accuracy)</li><li>精确率 (Precision)</li><li>召回率 (Recall)</li><li>F1 分数</li></ul><h2 id="基准结果" tabindex="-1">基准结果 <a class="header-anchor" href="#基准结果" aria-label="Permalink to &quot;基准结果&quot;">​</a></h2><table tabindex="0"><thead><tr><th>模型</th><th>数据集</th><th>准确率</th></tr></thead><tbody><tr><td>Transformer</td><td>IR Spectra</td><td>95.2%</td></tr><tr><td>CNN</td><td>Raman</td><td>92.8%</td></tr><tr><td>LSTM</td><td>NMR</td><td>89.5%</td></tr></tbody></table><h2 id="运行基准测试" tabindex="-1">运行基准测试 <a class="header-anchor" href="#运行基准测试" aria-label="Permalink to &quot;运行基准测试&quot;">​</a></h2><div class="language-python vp-adaptive-theme"><button title="Copy Code" class="copy"></button><span class="lang">python</span><pre class="shiki shiki-themes github-light github-dark vp-code" tabindex="0"><code><span class="line"><span style="--shiki-light:#D73A49;--shiki-dark:#F97583;">import</span><span style="--shiki-light:#24292E;--shiki-dark:#E1E4E8;"> spectral_hub </span><span style="--shiki-light:#D73A49;--shiki-dark:#F97583;">as</span><span style="--shiki-light:#24292E;--shiki-dark:#E1E4E8;"> sh</span></span>
<span class="line"></span>
<span class="line"><span style="--shiki-light:#6A737D;--shiki-dark:#6A737D;"># 运行基准测试</span></span>
<span class="line"><span style="--shiki-light:#24292E;--shiki-dark:#E1E4E8;">results </span><span style="--shiki-light:#D73A49;--shiki-dark:#F97583;">=</span><span style="--shiki-light:#24292E;--shiki-dark:#E1E4E8;"> sh.run_benchmark(</span><span style="--shiki-light:#032F62;--shiki-dark:#9ECBFF;">&#39;all&#39;</span><span style="--shiki-light:#24292E;--shiki-dark:#E1E4E8;">)</span></span>
<span class="line"><span style="--shiki-light:#005CC5;--shiki-dark:#79B8FF;">print</span><span style="--shiki-light:#24292E;--shiki-dark:#E1E4E8;">(results)</span></span></code></pre></div><h2 id="相关链接" tabindex="-1">相关链接 <a class="header-anchor" href="#相关链接" aria-label="Permalink to &quot;相关链接&quot;">​</a></h2><ul><li><a href="/spectral-hub/zh/tutorial">教程</a></li><li><a href="/spectral-hub/zh/api">API 参考</a></li></ul>`,12)]))}const u=t(l,[["render",n]]);export{k as __pageData,u as default};
