Skip to content

Commit

Permalink
feat: add knf-rs to crates folder (#12)
Browse files Browse the repository at this point in the history
  • Loading branch information
thewh1teagle authored Nov 28, 2024
1 parent f51bfbc commit 5e29c4f
Show file tree
Hide file tree
Showing 21 changed files with 1,265 additions and 7 deletions.
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
/target
target/
build/
*.onnx
*.wav
3 changes: 3 additions & 0 deletions .gitmodules
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
[submodule "crates/knf-rs/sys/knf"]
path = crates/knf-rs/sys/knf
url = https://github.com/csukuangfj/kaldi-native-fbank
21 changes: 21 additions & 0 deletions .vscode/c_cpp_properties.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
{
"configurations": [
{
"name": "Mac",
"includePath": [
"${workspaceFolder}/crates/knf-rs//**",
"${workspaceFolder}/crates/knf-rs/sys/knf/kaldi-native-fbank/csrc/**",
"${workspaceFolder}/crates/knf-rs/sys/knf/kaldi-native-fbank/**"
],
"defines": [],
"macFrameworkPath": [
"/Library/Developer/CommandLineTools/SDKs/MacOSX14.sdk/System/Library/Frameworks"
],
"compilerPath": "/opt/homebrew/opt/llvm/bin/clang",
"cStandard": "c17",
"cppStandard": "c++17",
"intelliSenseMode": "macos-clang-arm64"
}
],
"version": 4
}
5 changes: 4 additions & 1 deletion .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -1,5 +1,8 @@
{
"editor.formatOnPaste": true,
"editor.formatOnSave": true,
"rust-analyzer.check.command": "clippy"
"rust-analyzer.check.command": "clippy",
"clangd.fallbackFlags": [
"-I${workspaceFolder}/crates/knf-rs/sys/knf/kaldi-native-fbank/csrc",
]
}
4 changes: 0 additions & 4 deletions Cargo.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

5 changes: 4 additions & 1 deletion Cargo.toml
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
[workspace]
members = ["crates/knf-rs", "crates/knf-rs/sys"]

[package]
name = "pyannote-rs"
version = "0.2.7"
Expand All @@ -10,7 +13,7 @@ eyre = "0.6.12"
hound = "3.5.1"
ndarray = "0.16"
ort = "2.0.0-rc.9"
knf-rs = { version = "0.2.4", features = [] }
knf-rs = { path = "crates/knf-rs", version = "0.2.4", features = [] }

[features]
default = []
Expand Down
2 changes: 2 additions & 0 deletions crates/knf-rs/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
target/
build/
20 changes: 20 additions & 0 deletions crates/knf-rs/BUILDING.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,20 @@
# Building

_Prepare knf_

```console
git clone https://github.com/thewh1teagle/knf-rs --recursive
```

_Build_

```console
cargo build
```

_Build knf_

```console
cmake -B build . -DKALDI_NATIVE_FBANK_BUILD_PYTHON=OFF -DKALDI_NATIVE_FBANK_BUILD_TESTS=OFF
cmake --build build --config Release
```
Loading

0 comments on commit 5e29c4f

Please sign in to comment.