计数方法应用于PTB数据集

本文介绍了PTB数据集的处理方法,包括替换稀有单词为<unk>和数字为"N",以及ptb.py的作用,该脚本用于下载数据集并进行预处理。同时讨论了在PTB数据集上应用计数方法的效果,提到了不同SVD实现的计算速度差异。

摘要生成于 C知道 ,由 DeepSeek-R1 满血版支持, 前往体验 >

PTB数据集

内容如下:

一行保存一个句子;将稀有单词替换成特殊字符 < unk > ;将具体的数字替换 成“N”

 we 're talking about years ago before anyone heard of asbestos having any questionable properties 
 there is no asbestos in our products now 
 neither <unk> nor the researchers who studied the workers were aware of any research on smokers of the kent cigarettes 
 we have no useful information on whether users are at risk said james a. <unk> of boston 's <unk> cancer institute 
 dr. <unk> led a team of researchers from the national cancer institute and the medical schools of harvard university and boston university 

ptb.py

使用PTB数据集:

由下面这句话,可知用PTB数据集时候,是把所有句子首尾连接了。

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包

打赏作者

每天学点

你的鼓励将是我创作的最大动力

¥1 ¥2 ¥4 ¥6 ¥10 ¥20
扫码支付:¥1
获取中
扫码支付

您的余额不足,请更换扫码支付或充值

打赏作者

实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值