-
```
/opt/miniconda3/envs/pycorrector_ernie/lib/python3.8/site-packages/_distutils_hack/__init__.py:33: UserWarning: Setuptools is replacing distutils.
warnings.warn("Setuptools is replacing distut…
-
### Describe the bug
Please provide a clear and concise description of what the bug is. If applicable, add screenshots to help explain your problem, especially for visualization related problems.
…
-
你好,在进行模型训练时,出现ValueError: Expected input batch_size (544) to match target batch_size (512).请问这种问题如何解决?
-
pip安转完最新版本0.4.8,使用时,报一下错误,可否看下什么原因?
AttributeError: module 'pycorrector' has no attribute 'correct'
测试代码:
import pycorrector
corrected_sent, detail = pycorrector.correct('少先队员因该为老人让坐')
print(corr…
-
def load_toutiao_dataset2():
dataset = []
file_path = 'data/nlp7294/'
for file in os.listdir(file_path):
index = -1
with open(file_path+file, 'r') as f:
f…
-
### Describe the Question
Please provide a clear and concise description of what the question is.
### Describe your attempts
- [ ] I walked through the tutorials
- [x] I checked the documentatio…
-
```
import pycorrector
corrected_sent, detail = pycorrector.correct('少先队员因该为老人让坐')
```
接口上使用的是上面这种代码,处理单条文本,目前调用的延迟有3s。
个人猜测是每次调用的时候,每次都会重新加载kenlm模型,导致时间消耗太多。
如果这样,有什么方法是加载一次模型就可以的?个人尝试了如下方法:
`…
-
[pycorrector](https://github.com/shibing624/pycorrector/tree/0.4.8)/[pycorrector](https://github.com/shibing624/pycorrector/tree/0.4.8/pycorrector)/confusion_corrector.py
line 59: text_new = text[:…
-
### Describe the Question
Please provide a clear and concise description of what the question is.
https://github.com/shibing624/pycorrector/tree/master/pycorrector/t5 这个模型可以处理重复字或者词删除纠正吗。
就是前后文本字数…
-
直接使用docker run -it -v ~/.pycorrector:/root/.pycorrector shibing624/pycorrector:0.0.2 所的到的效果与下载源码所的到的效果不一致,模型文件都是使用2.8的那个默认文件。
Docker中的:
![image](https://github.com/shibing624/pycorrector/assets/5219…