error when importing ijson module python

2019-07-26 22:01发布

I need to parse some large (2 Gb+) files into python. I have tried it with the json module but I get a memory error as its methods all load the files at once. I then moved on into installing ijson which suposedly implements a iterator-based way of parsing the file. However when I run:

import ijson

I get exception : YAJL shared object not found.

Has anyone found a similar issue? any help would be greatly appreciated

Regards

标签: python json yajl
1条回答
放我归山
2楼-- · 2019-07-26 22:44

Thats an easy one, that is because you haven't installed the YAJL C library! ijson is a wrapper around the YAJL without it won't work.

查看更多
登录 后发表回答