Rikorose / DeepFilterNet

Noise supression using deep filtering
https://huggingface.co/spaces/hshr/DeepFilterNet2
Other
2.11k stars 196 forks source link

Unable to use libDF due to debug checks failing: duplicate name /convt3/Conv.bias #538

Open vaisest opened 3 months ago

vaisest commented 3 months ago

I have been trying to look into implementing a VST-plugin for use in Windows, but I'm unable to use the library even in a very basic way. I tried following the LADSPA example and tried initializing the model in the following way:

use df::tract::*;

fn main() {
    let dfp = DfParams::default();
    let rp = RuntimeParams::default_with_ch(2);
    let model = DfTract::new(dfp, &rp).expect("could not init");

    println!("{}", model.hop_size);
}

with the following Cargo.toml:

[package]
name = "dftestxd"
version = "0.1.0"
edition = "2021"

[dependencies]
deep_filter = { git = "https://github.com/Rikorose/DeepFilterNet.git", default-features = false, features = [
    "tract",
    "default-model",
] }

However, I get the following error:

thread 'main' panicked at src\main.rs:6:40:
could not init: running pass codegen

Caused by:
    0: after pass codegen
    1: after graph compaction
    2: duplicate name /convt3/Conv.bias
note: run with `RUST_BACKTRACE=1` environment variable to display a backtrace
error: process didn't exit successfully: `target\debug\dftestxd.exe` (exit code: 101)

However, if I build the executable with cargo run --release, then the model seems to initialise normally.