[問題] 增加原因-pickle 無法 serialize > 4GB

作者: magines (magines)   2019-01-18 00:50:00
首先先感謝看本文的人,文章可能有點長。
然後我是python 超新手,某些詞彙表達不是很精確..造成困擾的話,先說聲抱歉。
基本上問題就是:
OverflowError: cannot serialize a bytes object larger than 4 GiB
*************來自github作者,聲明發生這個問題的原因*****************
Hi, this is a common problem and stems from some of the patents
having a crazily large amount of text in them.
Reduce the size of the sample on which you're running inference.
E.g., instead of 20% (0.2), reduce it to 0.05 to start with and
try ratcheting it up slowly.
*********結論:patent檔案太大了
參考
https://github.com/google/patents-public-data/issues/16
*****請問要怎麼切檔案?
他把所有的檔案,存進一個叫td的東西(在python 上面打 td,他只會出現
<train_data.LandscapeTrainingDataUtil at 0x1369595c0>
完全沒有想法要怎麼切,也不知道他長怎樣....
作者: Neisseria (Neisseria)   2019-01-18 08:58:00
未看先猜檔案系統問題
作者: magines (magines)   2019-01-18 09:39:00
雖然不懂,不過還是謝謝你^^
作者: acer1832a (Mike)   2019-01-18 17:06:00
你的Python是裝32bit還是64bit?
作者: benson415 (沛行)   2019-01-18 20:28:00
LandscapeTrainingDataUtil is a class :)問題不只是protocol,你dump的時候還要by batch你可以用buffer去接每個batch,再去讀或寫
作者: alen84204 (Dana)   2019-01-20 01:50:00
原始檔案切割呢(訓練樣) 切成10分 分開跑

Links booklink

Contact Us: admin [ a t ] ucptt.com