Synthesis & Export 合成与导出

SXSEditor synthesizes singing voice using the SoulX-Singer diffusion model on ONNX Runtime. This page covers the synthesis pipeline, playback controls, quality settings, and WAV export.

SXSEditor 使用 SoulX-Singer 扩散模型在 ONNX Runtime 上合成歌声。本页涵盖合成管线、播放控制、质量设置和 WAV 导出。

How Synthesis Works 合成工作原理

When you press Play, SXSEditor runs the SVS pipeline:

按播放时,SXSEditor 会运行 SVS 管线:

  1. Prepares input: Collects MIDI notes, lyrics, pitch curve, and singer data.准备输入:收集 MIDI 音符、歌词、音高曲线和歌手数据。
  2. Processes text: Converts lyrics to phoneme sequences using language-specific processing.文本处理:使用语言特定处理将歌词转换为音素序列。
  3. Encodes: Runs 5 encoder models (text, pitch, note type, F0, condition embedding).编码:运行 5 个编码器模型(文本、音高、音符类型、F0、条件嵌入)。
  4. Runs diffusion: Iteratively denoises a mel spectrogram using the diffusion model.扩散:使用扩散模型迭代地对梅尔频谱图去噪。
  5. Vocalizes: Converts the mel spectrogram to a waveform using the vocoder.声码器:使用声码器将梅尔频谱图转换为波形。
  6. Plays audio: Outputs the waveform through the audio system.播放:通过音频系统输出波形。
ℹ️

The synthesis pipeline uses 9 ONNX model files in total. The model operates internally at 24000 Hz with a hop size of 480. Playback now defaults to 48000 Hz — the 24 kHz model output is linearly upsampled for playback. The first synthesis is always slower because all models must be loaded into GPU memory; subsequent syntheses reuse the loaded pipeline.

合成管线共使用 9 个 ONNX 模型文件。模型内部以 24000 Hz 运行,hop size 为 480。播放默认采样率现在为 48000 Hz——24 kHz 模型输出经线性上采样后播放。首次合成总是较慢,因为所有模型都要加载到 GPU 显存;之后的合成会复用已加载的管线。

Playback Controls 播放控制

Fragment-Level Playback 片段级播放

In the Fragment Editor, ▶ Play synthesizes and plays only the current fragment. This is useful for quick previews while editing. It uses the "Preview Inference Parameters" from Settings (fewer diffusion steps = faster response).

在片段编辑器中,▶ Play 仅合成并播放当前片段。便于编辑时快速预览。它使用设置中的"预览推理参数"(扩散步数更少 = 响应更快)。

ℹ️

Synthesis Cancellation — a cancel button appears during synthesis (both preview and export). Cancellation is cooperative: GPU inference exits at safe checkpoints between diffusion steps, preventing the D3D device-hung crash that occurred with the old force-terminate approach. The cancellation is near-instant for Euler/Heun samplers and completes at the next sub-stage for STORK-2.

取消合成——合成过程中(预览和导出均支持)会出现取消按钮。取消为协作式:GPU 推理在扩散步之间的安全检查点退出,避免了旧的强制终止方式导致的 D3D 设备挂起崩溃。Euler/Heun 求解器下取消近乎即时,STORK-2 则在下一个 sub-stage 完成后退出。

Preview vs Export Quality 预览与导出质量

SXSEditor uses two sets of inference parameters. Preview uses fewer steps for faster response; Export uses more steps for higher quality. Both are configurable in Settings.

SXSEditor 使用两套推理参数。预览使用较少步数以加快响应;导出使用更多步数以获得更高音质。两者均可在设置中配置。

Parameter参数 Preview (Default)预览(默认) Export (Default)导出(默认) Range范围
Diffusion Steps扩散步数 1616 3232 4–644–64
CFG StrengthCFG 引导强度 3.03.0 3.03.0 0–100–10
CFG RescaleCFG Rescale 系数 0.750.75 0.750.75 0–10–1
Sampler求解器 EulerEuler EulerEuler Euler / Heun / Extrapolated Euler / STORK-2Euler / Heun / Extrapolated Euler / STORK-2

Diffusion Sampler 扩散求解器

The sampler is the ODE solver used inside the diffusion loop. It decides how each denoising step combines model evaluations (NFE = number of function evaluations) into the mel-state update. Four solvers are available; the preview and export samplers are configured independently in Settings > Diffusion Sampler:

求解器是扩散循环中使用的 ODE 求解器,决定每个去噪步如何将模型推理(NFE = 模型评估次数)组合为 mel 状态更新。提供四种求解器;预览与导出的求解器可在 设置 > 扩散求解器 中独立配置:

ℹ️

Extrapolated Euler and STORK-2 carry cross-step velocity state. In chunked preview inference (long fragments split into chunks), this state resets at each chunk boundary, reducing their benefit — for chunked previews prefer Euler or Heun. The Export dialog exposes a Sampler dropdown so you can override the export sampler per export without changing the global setting.

Extrapolated Euler 与 STORK-2 需要跨步速度状态。分块预览推理(长片段切成多块)时,每块边界都会重置状态,使其优势减弱——分块预览建议使用 Euler 或 Heun。导出对话框提供求解器下拉框,可在不修改全局设置的情况下为本次导出单独覆盖求解器。

Diffusion Steps 扩散步数

The diffusion model iteratively denoises a mel spectrogram. The number of steps controls the trade-off between quality and speed:

扩散模型会迭代地对梅尔频谱图去噪。步数控制质量与速度的权衡:

CFG Strength CFG 引导强度

Classifier-Free Guidance (CFG) strength controls how closely the output adheres to the input conditions (notes, lyrics, pitch):

无分类器引导(CFG)强度控制输出与输入条件(音符、歌词、音高)的贴合程度:

CFG Rescale CFG Rescale 系数

The CFG rescale coefficient mitigates over-guidance artifacts caused by high CFG strength. Recommended: 0.5–0.9. Range: 0–1.

CFG rescale 系数用于缓解高 CFG 强度造成的过度引导伪影。推荐:0.5–0.9。范围:0–1。

Exporting to WAV 导出为 WAV

Exporting a Single Fragment 导出单个片段

In the Fragment Editor, click 💿 Export:

在片段编辑器中,点击 💿 Export

  1. The Export dialog opens, pre-filled with the export-quality parameters from Settings. You can override them for this export only: Sampler (Euler / Heun / Extrapolated Euler / STORK-2), Diffusion Steps, CFG Strength, CFG Rescale, Auto Shift, plus advanced options — Dynamic Thresholding (enable/disable, percentile 0.9–0.999) and CFG Schedule (constant / linear / cosine / custom) (the global Settings values are not changed).弹出 导出对话框,预填设置中的导出质量参数。可仅为本次导出覆盖:求解器(Euler / Heun / Extrapolated Euler / STORK-2)、扩散步数、CFG 强度、CFG Rescale、Auto Shift 以及高级选项——动态阈值(启用/禁用,百分位 0.9–0.999)和 CFG 调度(恒定 / 线性 / 余弦 / 自定义)(不会修改全局设置)。
  2. After confirming, the fragment is synthesized using the chosen parameters.确认后,片段按所选参数合成。
  3. A file save dialog appears. Choose a location and filename.弹出文件保存对话框。选择位置和文件名。
  4. The WAV file is saved at the selected export sample rate (default 48 kHz, selectable: 24 / 44.1 / 48 / 96 kHz, 16-bit PCM).WAV 文件按所选导出采样率保存(默认 48 kHz,可选:24 / 44.1 / 48 / 96 kHz,16-bit PCM)。

Exporting the Entire Project 导出整个项目

In the main window, click 📤 Export:

在主窗口中,点击 📤 Export

  1. The Export dialog opens (same options as single-fragment export: Sampler, Diffusion Steps, CFG, Auto Shift, Dynamic Thresholding, CFG Schedule).弹出 导出对话框(选项与单片段导出相同:求解器、扩散步数、CFG、Auto Shift、动态阈值、CFG 调度)。
  2. All fragments are synthesized sequentially using the chosen parameters.所有片段按所选参数顺序合成。
  3. Fragments are mixed together according to their timeline positions.片段根据时间线位置混合在一起。
  4. A file save dialog appears. Choose a save location.弹出文件保存对话框。选择保存位置。
  5. The mixed WAV file is saved at the selected export sample rate (default 48 kHz, selectable: 24 / 44.1 / 48 / 96 kHz, 16-bit PCM). Accompaniment audio tracks are mixed into the export.混合后的 WAV 文件按所选导出采样率保存(默认 48 kHz,可选:24 / 44.1 / 48 / 96 kHz,16-bit PCM)。伴奏音轨会混入导出。

Export Progress 导出进度

During export, a progress indicator shows:

导出过程中,进度指示器会显示:

Export-Time Options 导出时选项

The Export dialog exposes several options that can be overridden per export without changing global Settings:

导出对话框提供多项可仅为本次导出覆盖的选项,不会修改全局设置:

Exporting LRC Lyrics 导出 LRC 歌词

A new 📄 Export LRC button in the toolbar allows exporting the project lyrics as a timed LRC file. The LRC file contains timestamped lyric lines synchronized with the project timeline, compatible with standard LRC players and karaoke software.

工具栏新增 📄 Export LRC 按钮可将项目歌词导出为带时间戳的 LRC 文件。LRC 文件包含与项目时间线同步的带时间戳歌词行,兼容标准 LRC 播放器和卡拉 OK 软件。

Multi-Segment Synthesis 多段合成

Long audio is synthesized in segments. SXSEditor aligns F0 across segments using absolute-time alignment and applies per-segment autoShift f0Shift for wide-range songs, so multi-segment prompt mel frame counts stay consistent with the single-segment path. The vocoder processes audio in chunks (default 1008 frames, overlap 8 frames) with crossfade stitching.

长音频会分段合成。SXSEditor 使用绝对时间对齐跨段的 F0,并针对宽音域片段应用 per-segment autoShift f0Shift,使多段 prompt mel 帧数与单段路径一致。声码器按分片处理音频(默认 1008 帧,重叠 8 帧),交叉淡入淡出拼接。

Output Format 输出格式

Property属性 Value
Format格式 WAV (PCM)WAV(PCM)
Model Internal Rate模型内部采样率 24000 Hz (the SVS model always runs at 24 kHz)24000 Hz(SVS 模型始终以 24 kHz 运行)
Playback Sample Rate播放采样率 48000 Hz (default). 24 kHz model output is linearly upsampled.48000 Hz(默认)。24 kHz 模型输出经线性上采样。
Bit Depth (export)位深度(导出) 16-bit PCM16-bit PCM
Export Sample Rate (selectable)导出采样率(可选) 24000, 44100, 48000 (default), 96000 Hz. Linear upsampling from the 24 kHz model rate.24000、44100、48000(默认)、96000 Hz。从 24 kHz 模型率线性上采样。
Accompaniment Mixing伴奏混入 Accompaniment tracks are mixed into the final export alongside vocal fragments.伴奏音轨与人声片段一起混入最终导出。

Performance Tips 性能优化建议

💡

If synthesis is slow, try these adjustments:

如果合成速度慢,可尝试以下调整:

⚠️

If the synthesized voice sounds wrong or has artifacts:

如果合成声音异常或有伪影:

  • Check the reference audio — ensure it contains pure vocals with no background music or effects.检查参考音频——确保为纯人声,无背景音乐或效果。
  • Check lyrics — every note must have the correct lyric. Missing or wrong lyrics cause phoneme errors.检查歌词——每个音符必须有正确歌词。缺失或错误歌词会导致音素错误。
  • Check MIDI notes — verify pitches and timing match the intended melody.检查 MIDI 音符——确认音高和时序与预期旋律一致。
  • Check model precision — if using INT8, try FP16 for higher quality.检查模型精度——如使用 INT8,可尝试 FP16 以获得更高音质。
  • Increase diffusion steps — more steps = better quality (try 32 or 48 for export).增加扩散步数——更多步数 = 更高音质(导出可尝试 32 或 48 步)。