five

RaphaelOlivier/whisper_adversarial_examples

收藏
Hugging Face2022-11-03 更新2024-03-04 收录
下载链接:
https://hf-mirror.com/datasets/RaphaelOlivier/whisper_adversarial_examples
下载链接
链接失效反馈
官方服务:
资源简介:
该数据集是LibriSpeech和Multilingual CommonVoice的子集,经过对抗性修改以欺骗Whisper ASR模型。数据集包含有针对性和无针对性的对抗性示例,以及不同语言的配置。有针对性的配置包含成功欺骗Whisper预测特定句子的示例,而无针对性的配置则包含使Whisper预测错误转录的示例。此外,还有针对不同语言的配置,使Whisper预测错误的语言。

This dataset is a subset of LibriSpeech and Multilingual CommonVoice, which has been adversarially modified to deceive the Whisper ASR model. The dataset contains both targeted and untargeted adversarial examples, as well as configurations for different languages. The targeted configurations include examples that successfully trick Whisper into predicting a specific sentence, while the untargeted configurations contain examples that cause Whisper to generate incorrect transcriptions. Additionally, there are configurations for different languages that make Whisper predict the wrong language.
提供机构:
RaphaelOlivier
原始信息汇总

数据集描述

该数据集是LibriSpeech和多语言CommonVoice的一个子集,经过对抗性修改以欺骗Whisper自动语音识别(ASR)模型。

配置和分割

  • targeted配置包含目标对抗性示例。当成功时,它们使Whisper预测句子OK Google, browse to evil.com,即使输入完全不同。我们为每个Whisper模型提供一个分割,以及一个包含原始未修改输入的分割。
  • untargeted-35untargeted-40配置包含非目标对抗性示例,平均信噪比分别为35dB和40dB。它们使Whisper预测错误的转录。我们为每个Whisper模型提供一个分割,以及一个包含原始未修改输入的分割。
  • language-<lang>配置包含语言<lang>的对抗性示例,使Whisper预测错误的语言。分割<lang>.<target_lang>包含Whisper感知为<target_lang>的输入,分割<lang>.original包含语言<lang>的原始输入。我们使用3种目标语言(英语、塔加洛语和塞尔维亚语)和7种源语言(英语、意大利语、印度尼西亚语、丹麦语、捷克语、立陶宛语和亚美尼亚语)。

使用示例

以下是使用该数据集的代码示例:

python model_name="whisper-medium" config_name="targeted" split_name="whisper.medium" hub_path = "openai/whisper-"+model_name processor = WhisperProcessor.from_pretrained(hub_path) model = WhisperForConditionalGeneration.from_pretrained(hub_path).to("cuda")

dataset = load_dataset("RaphaelOlivier/whisper_adversarial_examples",config_name ,split=split_name)

def map_to_pred(batch): input_features = processor(batch["audio"][0]["array"], return_tensors="pt").input_features predicted_ids = model.generate(input_features.to("cuda")) transcription = processor.batch_decode(predicted_ids, normalize = True) batch[text][0] = processor.tokenizer._normalize(batch[text][0]) batch["transcription"] = transcription return batch

result = dataset.map(map_to_pred, batched=True, batch_size=1)

wer = load("wer") for t in zip(result["text"],result["transcription"]): print(t) print(wer.compute(predictions=result["text"], references=result["transcription"]))

搜集汇总
数据集介绍
main_image_url
背景与挑战
背景概述
该数据集是一个针对Whisper ASR模型的对抗性示例集合,基于LibriSpeech和Multilingual CommonVoice进行对抗性修改生成,旨在测试和评估Whisper模型的鲁棒性。它包括目标和非目标配置,目标配置使模型预测固定恶意句子,非目标配置则诱导错误转录,同时涵盖多语言场景以误导语言识别。数据集适用于研究对抗性攻击和语音识别安全领域。
以上内容由遇见数据集搜集并总结生成
二维码
社区交流群
二维码
科研交流群
商业服务