Open Kiteflyingee opened 6 years ago
大神你好,我16G内存,跑满了,最后写入文件的时候报 memoryerror,第一次用ElementTree,想只取一部分tu标签,如何实现,我看了api只有findall方法。或者有什么缩小内存占用的办法呢?
你可以改一下,例如第36行那里
if en and zh: x_data.append(en) y_data.append(zh)
限制x_data的大小,大于某个数字就停止了,先尝试训练小数据集
大神你好,我16G内存,跑满了,最后写入文件的时候报 memoryerror,第一次用ElementTree,想只取一部分tu标签,如何实现,我看了api只有findall方法。或者有什么缩小内存占用的办法呢?