fix(audio): update CoreML bridge for SileroVADRunner rename
Aligns with silero-coreml class rename to avoid CoreML type collision.
This commit is contained in:
@@ -3,11 +3,11 @@ import Foundation
|
||||
import SileroCoreML
|
||||
|
||||
private final class ChanoraSileroVadBox {
|
||||
let vad: SileroVAD
|
||||
let vad: SileroVADRunner
|
||||
|
||||
init() throws {
|
||||
let configuration = MLModelConfiguration()
|
||||
vad = try SileroVAD(configuration: configuration)
|
||||
vad = try SileroVADRunner(configuration: configuration)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -67,8 +67,8 @@ public func chanoraSileroVadProcess(
|
||||
setChanoraSileroLastError("SileroVAD probability output pointer is null")
|
||||
return -3
|
||||
}
|
||||
guard sampleCount == SileroVAD.chunkSize else {
|
||||
setChanoraSileroLastError("SileroVAD expected \(SileroVAD.chunkSize) samples, got \(sampleCount)")
|
||||
guard sampleCount == SileroVADRunner.chunkSize else {
|
||||
setChanoraSileroLastError("SileroVAD expected \(SileroVADRunner.chunkSize) samples, got \(sampleCount)")
|
||||
return -4
|
||||
}
|
||||
|
||||
|
||||
@@ -3,11 +3,11 @@ import Foundation
|
||||
import SileroCoreML
|
||||
|
||||
private final class ChanoraSileroVadBox {
|
||||
let vad: SileroVAD
|
||||
let vad: SileroVADRunner
|
||||
|
||||
init() throws {
|
||||
let configuration = MLModelConfiguration()
|
||||
vad = try SileroVAD(configuration: configuration)
|
||||
vad = try SileroVADRunner(configuration: configuration)
|
||||
}
|
||||
}
|
||||
|
||||
@@ -67,8 +67,8 @@ public func chanoraSileroVadProcess(
|
||||
setChanoraSileroLastError("SileroVAD probability output pointer is null")
|
||||
return -3
|
||||
}
|
||||
guard sampleCount == SileroVAD.chunkSize else {
|
||||
setChanoraSileroLastError("SileroVAD expected \(SileroVAD.chunkSize) samples, got \(sampleCount)")
|
||||
guard sampleCount == SileroVADRunner.chunkSize else {
|
||||
setChanoraSileroLastError("SileroVAD expected \(SileroVADRunner.chunkSize) samples, got \(sampleCount)")
|
||||
return -4
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user