Home
last modified time | relevance | path

Searched refs:sample_rate (Results 1 – 25 of 200) sorted by relevance

12345678

/external/webrtc/webrtc/modules/audio_device/include/
Daudio_device_defines.h87 int sample_rate, in OnDataAvailable() argument
105 int sample_rate, in OnData() argument
118 int sample_rate, in PushCaptureData() argument
127 int sample_rate, in PullRenderData() argument
152 AudioParameters(int sample_rate, size_t channels, size_t frames_per_buffer) in AudioParameters() argument
153 : sample_rate_(sample_rate), in AudioParameters()
156 frames_per_10ms_buffer_(static_cast<size_t>(sample_rate / 100)) {} in AudioParameters()
157 void reset(int sample_rate, size_t channels, size_t frames_per_buffer) { in reset() argument
158 sample_rate_ = sample_rate; in reset()
161 frames_per_10ms_buffer_ = static_cast<size_t>(sample_rate / 100); in reset()
[all …]
/external/autotest/server/site_tests/brillo_PlaybackAudioTest/
Dbrillo_PlaybackAudioTest.py69 def test_playback(self, fb_query, playback_cmd, sample_width, sample_rate, argument
81 sample_rate=sample_rate,
94 def test_audio(self, fb_client, playback_method, sample_rate, sample_width, argument
109 sample_rate=sample_rate,
117 self.host, num_channels, sample_rate, sample_width,
126 sample_rate=sample_rate,
157 for sample_rate in sample_rates_arr:
161 logging.info('Sample rate: %d', sample_rate)
168 sample_rate=sample_rate,
173 failed_params.append((sample_rate, sample_width,
/external/autotest/server/site_tests/brillo_RecordingAudioTest/
Dbrillo_RecordingAudioTest.py41 sample_rate, num_channels, rec_file): argument
61 (duration_secs, num_channels, sample_rate, sample_width,
67 (duration_secs, num_channels, sample_rate, rec_file))
70 (num_channels, duration_secs, sample_rate, sample_width,
77 sample_rate, num_channels, duration_secs): argument
96 sample_rate=sample_rate,
102 sample_rate=sample_rate,
150 for sample_rate in sample_rates_arr:
156 logging.info('Sample rate: %d', sample_rate)
164 sample_rate=sample_rate,
[all …]
/external/webrtc/webrtc/common_audio/
Dwav_header_unittest.cc95 int sample_rate = 0; in TEST() local
122 ReadWavHeader(&r, &num_channels, &sample_rate, &format, in TEST()
143 ReadWavHeader(&r, &num_channels, &sample_rate, &format, in TEST()
164 ReadWavHeader(&r, &num_channels, &sample_rate, &format, in TEST()
186 ReadWavHeader(&r, &num_channels, &sample_rate, &format, in TEST()
209 ReadWavHeader(&r, &num_channels, &sample_rate, &format, in TEST()
228 ReadWavHeader(&r, &num_channels, &sample_rate, &format, in TEST()
240 ReadWavHeader(&r, &num_channels, &sample_rate, &format, in TEST()
272 int sample_rate = 0; in TEST() local
278 ReadWavHeader(&r, &num_channels, &sample_rate, &format, in TEST()
[all …]
Dwav_header.cc63 int sample_rate, in CheckWavParameters() argument
70 if (num_channels == 0 || sample_rate <= 0 || bytes_per_sample == 0) in CheckWavParameters()
72 if (static_cast<uint64_t>(sample_rate) > std::numeric_limits<uint32_t>::max()) in CheckWavParameters()
79 if (static_cast<uint64_t>(sample_rate) * num_channels * bytes_per_sample > in CheckWavParameters()
138 static inline uint32_t ByteRate(size_t num_channels, int sample_rate, in ByteRate() argument
140 return static_cast<uint32_t>(num_channels * sample_rate * bytes_per_sample); in ByteRate()
150 int sample_rate, in WriteWavHeader() argument
154 RTC_CHECK(CheckWavParameters(num_channels, sample_rate, format, in WriteWavHeader()
168 WriteLE32(&header.fmt.SampleRate, sample_rate); in WriteWavHeader()
169 WriteLE32(&header.fmt.ByteRate, ByteRate(num_channels, sample_rate, in WriteWavHeader()
[all …]
Dwav_file.h29 virtual int sample_rate() const = 0;
42 WavWriter(const std::string& filename, int sample_rate, size_t num_channels);
53 int sample_rate() const override { return sample_rate_; } in sample_rate() function
81 int sample_rate() const override { return sample_rate_; } in sample_rate() function
104 int sample_rate,
Dwav_file.cc43 s << "Sample rate: " << sample_rate() << " Hz, Channels: " << num_channels() in FormatAsString()
45 << (1.f * num_samples()) / (num_channels() * sample_rate()) << " s"; in FormatAsString()
101 WavWriter::WavWriter(const std::string& filename, int sample_rate, in WavWriter() argument
103 : sample_rate_(sample_rate), in WavWriter()
155 int sample_rate, in rtc_WavOpen() argument
158 new webrtc::WavWriter(filename, sample_rate, num_channels)); in rtc_WavOpen()
172 return reinterpret_cast<const webrtc::WavWriter*>(wf)->sample_rate(); in rtc_WavSampleRate()
/external/tensorflow/tensorflow/python/ops/signal/
Dmel_ops.py69 def _validate_arguments(num_mel_bins, sample_rate, argument
74 if sample_rate <= 0.0:
75 raise ValueError('sample_rate must be positive. Got: %s' % sample_rate)
82 if upper_edge_hertz > sample_rate / 2:
85 % (upper_edge_hertz, sample_rate))
93 sample_rate=8000, argument
154 _validate_arguments(num_mel_bins, sample_rate,
159 sample_rate = ops.convert_to_tensor(
160 sample_rate, dtype, name='sample_rate')
169 nyquist_hertz = sample_rate / 2.0
/external/autotest/server/brillo/feedback/
Dclosed_loop_audio_client.py151 sample_rate=_DEFAULT_SAMPLE_RATE, argument
162 self.sample_rate = sample_rate
170 (num_channels, duration_secs, sample_rate, sample_width,
192 sample_rate=self.sample_rate,
227 sample_rate=self.sample_rate,
275 sample_rate=_DEFAULT_SAMPLE_RATE, argument
291 self.sample_rate = sample_rate
304 self.sample_rate, self.sample_width,
326 sample_rate=self.sample_rate,
/external/adhd/cras/src/server/
Dcras_dsp_mod_builtin.c18 unsigned long sample_rate) in empty_instantiate() argument
63 unsigned long sample_rate) in swap_lr_instantiate() argument
113 unsigned long sample_rate) in invert_lr_instantiate() argument
159 unsigned long sample_rate) in mix_stereo_instantiate() argument
216 unsigned long sample_rate) in dcblock_instantiate() argument
273 int sample_rate; member
280 static int eq_instantiate(struct dsp_module *module, unsigned long sample_rate) in eq_instantiate() argument
286 data->sample_rate = (int) sample_rate; in eq_instantiate()
301 float nyquist = data->sample_rate / 2; in eq_run()
346 int sample_rate; member
[all …]
Dcras_dsp.c32 int sample_rate; member
72 if (cras_dsp_pipeline_instantiate(pipeline, ctx->sample_rate) != 0) { in prepare_pipeline()
77 if (cras_dsp_pipeline_get_sample_rate(pipeline) != ctx->sample_rate) { in prepare_pipeline()
80 ctx->sample_rate); in prepare_pipeline()
149 struct cras_dsp_context *cras_dsp_context_new(int sample_rate, in cras_dsp_context_new() argument
156 ctx->sample_rate = sample_rate; in cras_dsp_context_new()
/external/tensorflow/tensorflow/python/kernel_tests/
Dsummary_v1_audio_op_test.py37 def _CheckProto(self, audio_summ, sample_rate, num_channels, length_frames): argument
47 }""" % (i, sample_rate, num_channels, length_frames) for i in xrange(3))
60 sample_rate = 8000
62 "snd", const, max_outputs=3, sample_rate=sample_rate)
68 self._CheckProto(audio_summ, sample_rate, channels, num_frames)
/external/tensorflow/tensorflow/examples/speech_commands/
Dfreeze.py63 def create_inference_graph(wanted_words, sample_rate, clip_duration_ms, argument
89 len(words_list), sample_rate, clip_duration_ms, window_size_ms,
115 sample_rate,
125 sample_rate = model_settings['sample_rate']
127 1000) / sample_rate
129 1000) / sample_rate
134 sample_rate=sample_rate,
161 FLAGS.wanted_words, FLAGS.sample_rate, FLAGS.clip_duration_ms,
Dgenerate_streaming_test_wav.py89 len(words_list), FLAGS.sample_rate, FLAGS.clip_duration_ms,
97 output_audio_sample_count = FLAGS.sample_rate * FLAGS.test_duration_seconds
105 (background_segment_duration_ms * FLAGS.sample_rate) / 1000)
107 (FLAGS.clip_duration_ms * FLAGS.sample_rate) / 1000)
109 ((background_crossover_ms / 2) * FLAGS.sample_rate) / 1000)
129 word_stride_samples = int((word_stride_ms * FLAGS.sample_rate) / 1000)
131 (FLAGS.clip_duration_ms * FLAGS.sample_rate) / 1000)
132 word_gap_samples = int((FLAGS.word_gap_ms * FLAGS.sample_rate) / 1000)
140 output_offset_ms = (output_offset * 1000) / FLAGS.sample_rate
162 FLAGS.sample_rate)
/external/autotest/server/brillo/
Daudio_utils.py67 def check_wav_file(filename, num_channels=None, sample_rate=None, argument
87 if sample_rate is not None and chk_file.getframerate() != sample_rate:
89 sample_rate, chk_file.getframerate())
106 def generate_sine_file(host, num_channels, sample_rate, sample_width, argument
130 sample_width * _BITS_PER_BYTE, sample_rate,
175 sample_rate): argument
207 1.0 / sample_rate)
208 fft_freqs_rec = numpy.fft.rfftfreq(len(rec_data), 1.0 / sample_rate)
/external/tensorflow/tensorflow/core/lib/wav/
Dwav_io.cc46 char sample_rate[4]; member
135 Status EncodeAudioAsS16LEWav(const float* audio, size_t sample_rate, in EncodeAudioAsS16LEWav() argument
150 if (sample_rate == 0 || sample_rate > kuint32max) { in EncodeAudioAsS16LEWav()
152 sample_rate); in EncodeAudioAsS16LEWav()
162 const size_t bytes_per_second = sample_rate * kBytesPerSample * num_channels; in EncodeAudioAsS16LEWav()
191 core::EncodeFixed32(format_chunk->sample_rate, sample_rate); in EncodeAudioAsS16LEWav()
214 uint32* sample_rate) { in DecodeLin16WaveAsFloatVector() argument
240 TF_RETURN_IF_ERROR(ReadValue<uint32>(wav_string, sample_rate, &offset)); in DecodeLin16WaveAsFloatVector()
262 const uint32 expected_bytes_per_second = bytes_per_sample * *sample_rate; in DecodeLin16WaveAsFloatVector()
267 " (sample_rate=", *sample_rate, ", bytes_per_sample=", bytes_per_sample, in DecodeLin16WaveAsFloatVector()
/external/webrtc/webrtc/modules/audio_processing/beamformer/
Dnonlinear_beamformer_test.cc46 WavWriter out_file(FLAGS_o, in_file.sample_rate(), 1); in main()
54 bf.Initialize(kChunkSizeMs, in_file.sample_rate()); in main()
57 FLAGS_i.c_str(), in_file.num_channels(), in_file.sample_rate()); in main()
59 FLAGS_o.c_str(), out_file.num_channels(), out_file.sample_rate()); in main()
62 rtc::CheckedDivExact(in_file.sample_rate(), kChunksPerSecond), in main()
65 rtc::CheckedDivExact(out_file.sample_rate(), kChunksPerSecond), in main()
/external/webrtc/webrtc/audio/
Daudio_sink.h32 int sample_rate, in Data()
37 sample_rate(sample_rate), in Data()
43 int sample_rate; // Sample rate in Hz. member
/external/webrtc/webrtc/voice_engine/
Dvoe_base_impl.h78 int sample_rate,
88 int sample_rate,
94 int sample_rate,
98 int sample_rate,
128 const void* audio_data, uint32_t sample_rate, size_t number_of_channels,
132 void GetPlayoutData(int sample_rate, size_t number_of_channels,
Dvoe_base_impl.cc114 const int16_t* audio_data, int sample_rate, in OnDataAvailable() argument
123 voe_channels, number_of_voe_channels, audio_data, sample_rate, in OnDataAvailable()
134 PushCaptureData(voe_channels[i], audio_data, 16, sample_rate, in OnDataAvailable()
143 int bits_per_sample, int sample_rate, in OnData() argument
145 PushCaptureData(voe_channel, audio_data, bits_per_sample, sample_rate, in OnData()
150 int bits_per_sample, int sample_rate, in PushCaptureData() argument
159 sample_rate, number_of_frames, number_of_channels); in PushCaptureData()
160 channel_ptr->PrepareEncodeAndSend(sample_rate); in PushCaptureData()
166 int sample_rate, in PullRenderData() argument
172 assert(number_of_frames == static_cast<size_t>(sample_rate / 100)); in PullRenderData()
[all …]
/external/python/cpython2/Lib/
Dsunaudio.py26 sample_rate = get_long_be(fp.read(4))
35 return (data_size, encoding, sample_rate, channels, info)
41 data_size, encoding, sample_rate, channels, info = hdr
47 print 'Sample rate:', sample_rate
/external/tensorflow/tensorflow/lite/experimental/microfrontend/python/kernel_tests/
Daudio_microfrontend_op_test.py45 sample_rate=SAMPLE_RATE,
64 sample_rate=SAMPLE_RATE,
86 sample_rate=SAMPLE_RATE,
106 sample_rate=SAMPLE_RATE,
129 sample_rate=SAMPLE_RATE,
149 sample_rate=SAMPLE_RATE,
/external/tensorflow/tensorflow/core/kernels/
Dsummary_audio_op.cc49 float sample_rate = sample_rate_attr_; in Compute() local
52 sample_rate = sample_rate_tensor.scalar<float>()(); in Compute()
54 OP_REQUIRES(c, sample_rate > 0.0f, in Compute()
73 sa->set_sample_rate(sample_rate); in Compute()
83 size_t sample_rate_truncated = lrintf(sample_rate); in Compute()
/external/flac/libFLAC/
Dformat.c200 FLAC_API FLAC__bool FLAC__format_sample_rate_is_valid(unsigned sample_rate) in FLAC__format_sample_rate_is_valid() argument
202 if(sample_rate == 0 || sample_rate > FLAC__MAX_SAMPLE_RATE) { in FLAC__format_sample_rate_is_valid()
209 FLAC_API FLAC__bool FLAC__format_blocksize_is_subset(unsigned blocksize, unsigned sample_rate) in FLAC__format_blocksize_is_subset() argument
213 else if(sample_rate <= 48000 && blocksize > 4608) in FLAC__format_blocksize_is_subset()
219 FLAC_API FLAC__bool FLAC__format_sample_rate_is_subset(unsigned sample_rate) in FLAC__format_sample_rate_is_subset() argument
222 !FLAC__format_sample_rate_is_valid(sample_rate) || in FLAC__format_sample_rate_is_subset()
224 sample_rate >= (1u << 16) && in FLAC__format_sample_rate_is_subset()
225 !(sample_rate % 1000 == 0 || sample_rate % 10 == 0) in FLAC__format_sample_rate_is_subset()
/external/webrtc/webrtc/modules/audio_device/android/
Daudio_manager.cc177 jint sample_rate, in CacheAudioParameters() argument
189 env, sample_rate, channels, hardware_aec, hardware_agc, hardware_ns, in CacheAudioParameters()
194 jint sample_rate, in OnCacheAudioParameters() argument
207 ALOGD("sample_rate: %d", sample_rate); in OnCacheAudioParameters()
217 playout_parameters_.reset(sample_rate, static_cast<size_t>(channels), in OnCacheAudioParameters()
219 record_parameters_.reset(sample_rate, static_cast<size_t>(channels), in OnCacheAudioParameters()

12345678