2024-10-01 00:17:08 发布
网友
我尝试了下面的代码,但它不起作用
import json with open("/Users/elton/20210228test2.ndjson") as f: test2data = ndjson.load(f)
这对我有用import ndjson而不是import json。更多信息请参见:https://pypi.org/project/ndjson/
import ndjson
import json
import ndjson # load from file-like objects with open('data.ndjson') as f: data = ndjson.load(f)
这对我有用
import ndjson
而不是import json
。更多信息请参见:https://pypi.org/project/ndjson/相关问题 更多 >
编程相关推荐