← 返回资讯屏轩教育 · 行业资讯

Speech and Audio Processing in Computing | 计算机中的口语/听力技术备考

2026-07-18 18:36 · 本文部分内容由AI辅助创作

📚 Speech and Audio Processing in Computing | 计算机中的口语/听力技术备考

In Year 9 OCR Computer Science, students often explore how computers capture, process, and respond to spoken language and audio signals. This revision guide focuses on the key concepts behind speech recognition, digital audio representation, and the systems that enable computers to "listen" and "speak". You will learn about sampling, binary representation of sound, and the role of artificial intelligence in voice assistants.

在九年级 OCR 计算机科学课程中,学生通常会学习计算机如何捕捉、处理并响应口语和音频信号。本复习指南将重点讲解语音识别、数字音频表示以及让计算机能够“听”和“说”的系统背后的关键概念。你将了解采样、声音的二进制表示,以及人工智能在语音助手中的作用。

1. How Computers Capture Sound | 计算机如何捕捉声音

Sound is an analogue wave that must be converted into digital data for a computer to process it. A microphone captures sound waves and converts them into an electrical signal. This signal is then passed through an analogue-to-digital converter (ADC), which measures the wave's amplitude at regular intervals. These measurements become a stream of binary numbers that the computer can store and manipulate.

声音是一种模拟波,必须转换成数字数据才能让计算机处理。麦克风捕捉声波并将其转换为电信号。然后该信号通过模数转换器 (ADC),以固定间隔测量波的振幅。这些测量值变成计算机可以存储和处理的二进制数流。

2. Sampling Rate and Bit Depth | 采样率和位深度

Two critical factors determine the quality of a digital audio recording: the sampling rate and the bit depth. The sampling rate is the number of samples taken per second, measured in hertz (Hz). Common rates include 44,100 Hz for CD quality. A higher sampling rate captures higher frequencies more accurately. Bit depth refers to the number of bits used to store each sample, which determines the precision of the amplitude value. A higher bit depth provides more dynamic range and reduces quantization noise.

决定数字音频录音质量的两个关键因素是采样率和位深度。采样率是每秒采集的样本数,以赫兹 (Hz) 为单位。常见采样率包括 CD 质量的 44100 Hz。更高的采样率能更准确地捕捉高频。位深度是指用于存储每个样本的比特数,决定了振幅值的精度。更高的位深度能提供更大的动态范围并减少量化噪声。

ParameterDescriptionImpact on Quality
Sampling rateSamples per second (Hz)Higher = more accurate high frequencies
Bit depthBits per sample (e.g., 16, 24)Higher = finer amplitude detail

中文对照:采样率(每秒样本数,单位 Hz)越高,高频表现越准确;位深度(每个样本的比特数)越高,振幅细节越精细。

3. Nyquist Theorem | 奈奎斯特定理

The Nyquist theorem states that the sampling rate must be at least twice the highest frequency in the original sound to avoid aliasing. If the sampling rate is too low, high-frequency components are misrepresented as lower frequencies, causing distortion. For example, human hearing ranges up to about 20 kHz, so CD-quality audio uses a rate slightly above 40 kHz (44.1 kHz).

奈奎斯特定理指出,采样率必须至少是原始声音最高频率的两倍,以避免混叠。如果采样率太低,高频成分会被错误地表示为较低频率,导致失真。例如,人类的听觉范围最高约 20 kHz,因此 CD 质量音频使用略高于 40 kHz 的采样率 (44.1 kHz)。

Sample rate ≥ 2 × fmax

采样率 ≥ 2 × 最高频率

4. Calculating File Size for Audio | 计算音频文件大小

A standard formula is used to estimate the storage required for uncompressed digital audio. You multiply the sampling rate, bit depth, number of channels (e.g., 1 for mono, 2 for stereo), and the duration in seconds. The result is in bits, which can be converted to bytes by dividing by 8. This calculation helps students understand the trade-offs between quality and storage.

可以使用标准公式估算无压缩数字音频所需的存储空间。你需要将采样率、位深度、声道数(例如单声道为 1,立体声为 2)和时长(秒)相乘。结果以比特为单位,除以 8 可转换为字节。这个计算帮助学生理解质量与存储之间的权衡。

File size (bits) = Sampling rate (Hz) × Bit depth × Channels × Time (s)

文件大小(比特) = 采样率(Hz) × 位深度 × 声道数 × 时间(秒)

5. What is Speech Recognition? | 什么是语音识别?

Speech recognition is the technology that allows a computer to identify and interpret spoken words, converting them into text or commands. Modern systems use machine learning models trained on vast datasets of human speech. The process typically involves acoustic analysis, language modelling, and pattern matching. Applications include virtual assistants, dictation software, and accessibility tools.

语音识别是一种技术,使计算机能够识别和解读口头语言,并将其转换为文字或指令。现代系统使用基于大量人类语音数据集训练的机器学习模型。该过程通常包括声学分析、语言建模和模式匹配。应用包括虚拟助手、听写软件和无障碍工具。

广告 / Sponsored

6. Feature Extraction from Speech | 语音特征提取

Before a model can understand speech, raw audio is transformed into meaningful features. One common technique is Mel-Frequency Cepstral Coefficients (MFCCs), which mimic the human ear's response to different frequencies. The audio is divided into short frames, and for each frame, a spectrum is computed, then mapped to the mel scale. These coefficients form a compact representation of the speech signal.

在模型能够理解语音之前,原始音频会被转换为有意义的特征。一种常见技术是梅尔频率倒谱系数 (MFCC),它模拟了人耳对不同频率的响应。音频被分成短帧,对于每一帧计算频谱,然后映射到梅尔刻度。这些系数形成了语音信号的紧凑表示。

Other features include zero-crossing rate and spectral centroid. These help distinguish voiced from unvoiced sounds.

其他特征包括过零率和频谱质心。这些有助于区分浊音和清音。

7. Natural Language Processing in Voice Assistants | 语音助手中的自然语言处理

Once speech is converted to text, Natural Language Processing (NLP) figures out the user's intent. This involves tokenisation, part-of-speech tagging, and named entity recognition. Voice assistants like Siri or Alexa use intents and slots: an intent is the action the user wants (e.g., "set a reminder"), while slots are specific details (time, date, content).

一旦语音被转换为文字,自然语言处理 (NLP) 就会理解用户的意图。这涉及分词、词性标注和命名实体识别。像 Siri 或 Alexa 这样的语音助手使用意图和槽位:意图是用户想要的操作(例如“设置提醒”),而槽位是具体的细节(时间、日期、内容)。

Deep learning models, especially recurrent neural networks and transformers, have greatly improved NLP accuracy.

深度学习模型,特别是循环神经网络和 Transformer 架构,极大地提高了 NLP 的准确率。

8. Speech Synthesis: Text to Speech | 语音合成:文本到语音

Computers also need to "speak" back to users. Text-to-speech (TTS) synthesis converts written text into spoken audio. Older formant synthesis used acoustic rules, while modern concatenative synthesis stitches together recorded speech fragments. The latest neural TTS models generate highly natural, human-like voices by predicting waveforms directly from text using deep neural networks.

计算机还需要对用户“说话”。文本到语音 (TTS) 合成技术将书面文字转换为语音音频。较老的共振峰合成使用声学规则,而现代的拼接合成将录制的语音片段拼接起来。最新的神经 TTS 模型通过使用深度神经网络直接从文本预测波形,生成高度自然、类似人类的语音。

Examples: WaveNet, Tacotron.

示例:WaveNet、Tacotron。

9. Challenges in Speech Processing | 语音处理中的挑战

Despite advances, many challenges remain. Background noise, multiple speakers, accents, and homophones can confuse systems. Ethical considerations include privacy (always-on microphones), bias in training data (poor performance for certain dialects), and deepfake audio. Students should be aware of these limitations and debates.

尽管取得了进展,但仍存在许多挑战。背景噪声、多说话人、口音和同音词可能会让系统产生混淆。伦理考量包括隐私(始终开启的麦克风)、训练数据中的偏见(对某些方言识别不佳)以及深度伪造音频。学生应了解这些局限性和相关讨论。

10. Hardware for Audio Processing | 音频处理硬件

Audio processing requires specific hardware components. Sound cards or integrated audio chips contain ADCs and DACs (digital-to-analogue converters). Dedicated digital signal processors (DSPs) handle real-time audio effects, echo cancellation, and speech enhancement. In mobile devices, power-efficient audio codecs are essential for battery life.

音频处理需要特定的硬件组件。声卡或集成音频芯片包含 ADC 和 DAC(数模转换器)。专用的数字信号处理器 (DSP) 处理实时音频效果、回声消除和语音增强。在移动设备中,节能的音频编解码器对于电池续航至关重要。

Modern smartphones often include separate always-on low-power cores for keyword detection ("Hey Siri", "OK Google").

现代智能手机通常包含独立的低功耗唤醒核心,用于关键词检测(“嘿 Siri”、“OK Google”)。

11. Compression and Streaming | 压缩与流媒体传输

Uncompressed audio files are large, so compression techniques are essential for storage and streaming. Lossy compression, like MP3 and AAC, removes sounds that the human ear is less likely to notice, drastically reducing file size. Lossless compression, like FLAC, preserves all original data. When streaming, adaptive bitrate algorithms adjust audio quality based on network conditions.

无压缩音频文件非常大,因此压缩技术对于存储和流媒体传输至关重要。有损压缩,如 MP3 和 AAC,会去除人耳不太容易察觉的声音,从而大幅减小文件大小。无损压缩,如 FLAC,则保留所有原始数据。流媒体传输时,自适应比特率算法会根据网络状况调整音频质量。

12. Hands-on Revision Activities | 动手复习活动

To cement these concepts, try recording a short audio clip in Audacity, examine the waveform, and change the sample rate to hear aliasing. Use a visual programming tool like Scratch with extension blocks for speech recognition. Calculate file sizes for different settings. Discuss the impact of voice technology on society.

为了巩固这些概念,尝试在 Audacity 中录制一段短音频,查看波形,并更改采样率以听到混叠效果。使用带有语音识别扩展模块的可视化编程工具,如 Scratch。计算不同设置下的文件大小。讨论语音技术对社会的影响。

Cross-curricular links: physics of sound waves, maths of binary and data storage, ethics in technology.

跨学科联系:声波的物理原理、二进制与数据存储的数学、技术伦理。

Published by TutorHao | Computer Science Revision Series | aleveler.com

广告 / Sponsored
Linux高级程序设计(高等院校计算机技术十二五规划教材)/刘加海/季江民/浙江大学出版社
计算机 备考教辅 · 正版现货 · 与本文内容相关
查看详情 / View on Taobao参考价 ¥55.6

更多咨询请联系16621398022(同微信)

备考资讯每日更新,关注不错过
考纲变化 · 科目分析 · 学习方法
扫码关注公众号 tutorhao
在微信里长按二维码识别关注
或截图后用「扫一扫 → 相册」选择本图
公众号:tutorhao