Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func SetLogLevel ¶
func SetLogLevel(level LogLevel)
func SetLogrusLogLevel ¶ added in v0.2.3
func SetLogrusLogLevel(level LogLevel)
Types ¶
type Detector ¶
type Detector struct {
// contains filtered or unexported fields
}
func NewDetector ¶
func NewDetector(cfg DetectorConfig) (*Detector, error)
func (*Detector) ChangeLogLevel ¶
type DetectorConfig ¶
type DetectorConfig struct { // The path to the ONNX Silero VAD model file to load. ModelPath string // The sampling rate of the input audio samples. Supported values are 8000 and 16000. SampleRate int // The number of samples to process at each infer. WindowSize int // The probability threshold above which we detect speech. A good default is 0.5. Threshold float32 // The duration of silence to wait for each speech segment before separating it. MinSilenceDurationMs int // The padding to add to speech segments to avoid aggressive cutting. SpeechPadMs int }
func (DetectorConfig) IsValid ¶
func (c DetectorConfig) IsValid() error
Click to show internal directories.
Click to hide internal directories.