Repository navigation
Conversation
AudioSR was too slow to be practical, so the spec replaces it with VoiceFixer exported to ONNX and run in-app through ONNX Runtime, which means end users don't need a Python environment. tools/voicefixer_onnx/export.py writes the three graphs (front with soxr_hq-equivalent 4x upsampling and the GRU denoiser, back with the UNet and vocoder, post that keeps the original audio below 4.8kHz). pipeline.py is the reference implementation for the Dart port: it chunks long files with context so the output matches whole-file inference without crossfading. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Vendor the ONNX Runtime 1.23.2 C API headers and generate dart:ffi bindings with ffigen (only OrtGetApiBase and the OrtApi function table are needed). OnnxRuntime/OrtModel wrap environment, session and tensor handling, and VoiceFixer ports restore() from pipeline.py. tool/voicefixer_cli.dart runs one WAV file; its output is bit-identical to the Python reference on 8.9s and 36.4s (chunked) inputs. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
hook/build.dart downloads the official ONNX Runtime 1.23.2 release archive for the target OS/architecture (macOS, Linux and Windows on x64 and arm64), verifies its pinned SHA-256 and registers the library as a code asset, so Flutter bundles it on every desktop platform without touching the Xcode project or the CMake files. The archive is cached across builds, and the onnxruntime_library user define allows offline builds. The bindings are now @Native externals resolved through that asset, so OnnxRuntime no longer takes a library path. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The super-resolution step now runs VoiceFixer through ONNX Runtime in a background isolate instead of spawning the audiosr executable. Results are cached by the input file's SHA-256, so files shared between streams and work finished before a cancelled build are reused; cancelling stops the current model run within milliseconds and leaves no partial cache entry. The AudioSR-specific gain of 2.0 is dropped. The settings dialog replaces the AudioSR options with a VoiceFixer checkbox and a model download (resumable, SHA-256 checked) from the model-data-voicefixer-1 pre-release. The "previous data found" dialog is gone because the content-keyed cache is always safe to reuse. The app build workflows now skip releases whose tag does not start with "v", so publishing the model-data release does not attach app binaries to it. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The license page now lists VoiceFixer (MIT code, CC BY 4.0 weights) and ONNX Runtime with its third-party notices. The opt-in integration test downloads the model from the settings dialog, enables super-resolution and checks the build writes 44.1kHz audio. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Runs the weight-free vf_post.onnx through the ONNX Runtime library the build hook bundles, so the e2e CI job checks the native asset on macOS, Linux and Windows without downloading the model. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
On desktop, flutter test fails to start the app for the second file of a multi-file integration test run, so loop over the files instead. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Export writes the voices that still need super-resolution to sr_input.zip in the output folder. The notebook (colab/ super_resolution.ipynb) runs the same ONNX models with onnxruntime-gpu and returns sr_output.zip, which import copies into the cache keyed by input hash. With the Colab backend the build only uses cached results and needs no local model. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Colab has no API for running a notebook from another app, so the user has to move zips through the browser. In Colab mode the build button is replaced by three steps (export, open Colab, import and build) that show what is done and what to do next. The downloaded sr_output.zip is found in Downloads when the window regains focus, and importing it starts the build. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
In Colab mode the main button becomes "Enhance on Colab and build…" and opens a three-page dialog (export, run the notebook, import and build) that starts at the first unfinished step. The step panel is kept on the feature/colab-step-panel branch. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
ONNX Runtime 1.23 is built for cuDNN 9.8. With the cuDNN 9.27 that Colab now ships, a vocoder Conv failed with CUDNN_FE HEURISTIC_QUERY_FAILED and ONNX Runtime silently fell back to the CPU, which takes hours. Install the matching cuDNN, disable the CPU fallback, and check the GPU with a short run before processing so a failure is reported at once. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Voices have different lengths, so the CUDA arena kept growing with new buffer sizes until a T4 ran out of memory after about 150 files. Extend the arena by exactly the requested size and shrink it after each run. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Re-running the setup cell in the same runtime created new sessions while the old ones still held the GPU memory, so cublasCreate failed. Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Replaces AudioSR (Python, too slow) with VoiceFixer running in-app through ONNX Runtime. No Python setup is required. The spec is in
docs/super-resolution.md.Changes
tools/voicefixer_onnx/export.py). Below 4.8kHz the output is replaced with the original audio, because VoiceFixer's resynthesis dropped Japanese consonants and attacks.hook/build.dartdownloads the official archive for the target OS and CPU, checks its SHA-256 and bundles it as a native asset.model-data-voicefixer-1pre-release that can resume and checks SHA-256.sr_input.zip. The notebookcolab/super_resolution.ipynbruns the same models with onnxruntime-gpu and returnssr_output.zip. Import checks the model ID and puts the results in the cache. With this backend the build uses only cached results and needs no local model.v*release tags, so model-data releases don't build the app.Testing
test/services/super_resolution_build_test.dartand runs only whenVOICEFIXER_MODEL_DIRis set.integration_test/super_resolution_flow_test.dartruns with--dart-define=SR_E2E=true. It downloads the model from the settings dialog, enables super-resolution, builds, and checks the output is 44.1kHz.integration_test/onnx_runtime_test.dart, which runs a small model that contains no weights. All three pass. Integration test files now run one per invocation, because on desktop a second file in the same run fails to start the app.pipeline.pyon 3 real voices, including one over 30 s. The app imported thatsr_output.zip. Unit tests cover export, then import, then building with the Colab backend.Not covered
v<version>, so the link works only after the next release.🤖 Generated with Claude Code