Class DenoiserConfig.Builder (4.78.0)

public static final class DenoiserConfig.Builder extends GeneratedMessage.Builder<DenoiserConfig.Builder> implements DenoiserConfigOrBuilder

Denoiser config. May not be supported for all models and may have no effect.

Protobuf type google.cloud.speech.v2.DenoiserConfig

Static Methods

getDescriptor()

public static final Descriptors.Descriptor getDescriptor()
Returns
Type Description
Descriptor

Methods

build()

public DenoiserConfig build()
Returns
Type Description
DenoiserConfig

buildPartial()

public DenoiserConfig buildPartial()
Returns
Type Description
DenoiserConfig

clear()

public DenoiserConfig.Builder clear()
Returns
Type Description
DenoiserConfig.Builder
Overrides

clearDenoiseAudio()

public DenoiserConfig.Builder clearDenoiseAudio()

Denoise audio before sending to the transcription model.

bool denoise_audio = 1;

Returns
Type Description
DenoiserConfig.Builder

This builder for chaining.

clearSnrThreshold()

public DenoiserConfig.Builder clearSnrThreshold()

Signal-to-Noise Ratio (SNR) threshold for the denoiser. Here SNR means the loudness of the speech signal. Audio with an SNR below this threshold, meaning the speech is too quiet, will be prevented from being sent to the transcription model.

If snr_threshold=0, no filtering will be applied.

float snr_threshold = 2;

Returns
Type Description
DenoiserConfig.Builder

This builder for chaining.

getDefaultInstanceForType()

public DenoiserConfig getDefaultInstanceForType()
Returns
Type Description
DenoiserConfig

getDenoiseAudio()

public boolean getDenoiseAudio()

Denoise audio before sending to the transcription model.

bool denoise_audio = 1;

Returns
Type Description
boolean

The denoiseAudio.

getDescriptorForType()

public Descriptors.Descriptor getDescriptorForType()
Returns
Type Description
Descriptor
Overrides

getSnrThreshold()

public float getSnrThreshold()

Signal-to-Noise Ratio (SNR) threshold for the denoiser. Here SNR means the loudness of the speech signal. Audio with an SNR below this threshold, meaning the speech is too quiet, will be prevented from being sent to the transcription model.

If snr_threshold=0, no filtering will be applied.

float snr_threshold = 2;

Returns
Type Description
float

The snrThreshold.

internalGetFieldAccessorTable()

protected GeneratedMessage.FieldAccessorTable internalGetFieldAccessorTable()
Returns
Type Description
FieldAccessorTable
Overrides

isInitialized()

public final boolean isInitialized()
Returns
Type Description
boolean
Overrides

mergeFrom(DenoiserConfig other)

public DenoiserConfig.Builder mergeFrom(DenoiserConfig other)
Parameter
Name Description
other DenoiserConfig
Returns
Type Description
DenoiserConfig.Builder

mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)

public DenoiserConfig.Builder mergeFrom(CodedInputStream input, ExtensionRegistryLite extensionRegistry)
Parameters
Name Description
input CodedInputStream
extensionRegistry ExtensionRegistryLite
Returns
Type Description
DenoiserConfig.Builder
Overrides
Exceptions
Type Description
IOException

mergeFrom(Message other)

public DenoiserConfig.Builder mergeFrom(Message other)
Parameter
Name Description
other Message
Returns
Type Description
DenoiserConfig.Builder
Overrides

setDenoiseAudio(boolean value)

public DenoiserConfig.Builder setDenoiseAudio(boolean value)

Denoise audio before sending to the transcription model.

bool denoise_audio = 1;

Parameter
Name Description
value boolean

The denoiseAudio to set.

Returns
Type Description
DenoiserConfig.Builder

This builder for chaining.

setSnrThreshold(float value)

public DenoiserConfig.Builder setSnrThreshold(float value)

Signal-to-Noise Ratio (SNR) threshold for the denoiser. Here SNR means the loudness of the speech signal. Audio with an SNR below this threshold, meaning the speech is too quiet, will be prevented from being sent to the transcription model.

If snr_threshold=0, no filtering will be applied.

float snr_threshold = 2;

Parameter
Name Description
value float

The snrThreshold to set.

Returns
Type Description
DenoiserConfig.Builder

This builder for chaining.