db4b9f4d50af9e83733fc301c32e85cbe6d9c812,conceptnet5/builders/json_to_solr.py,,convert_to_solr,#Any#Any#,12
Before Change
writer = SolrEdgeWriter(out_stream)
for line in in_stream:
if not line.strip():
continue
info = json.loads(line.strip().decode("utf-8"))
writer.write(info)
writer.close()
if __name__ == "__main__":
After Change
out = codecs.open(output_filename, encoding="utf-8")
print("{", file=out)
for info in read_json_stream(input_filename) :
boost = info["weight"]
if "surfaceText" in info and info["surfaceText"] is None:
del info["surfaceText"]
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 8
Instances Project Name: commonsense/conceptnet5
Commit Name: db4b9f4d50af9e83733fc301c32e85cbe6d9c812
Time: 2014-02-25
Author: rob@luminoso.com
File Name: conceptnet5/builders/json_to_solr.py
Class Name:
Method Name: convert_to_solr
Project Name: commonsense/conceptnet5
Commit Name: db4b9f4d50af9e83733fc301c32e85cbe6d9c812
Time: 2014-02-25
Author: rob@luminoso.com
File Name: conceptnet5/builders/json_to_csv.py
Class Name:
Method Name: convert_to_tab_separated
Project Name: commonsense/conceptnet5
Commit Name: 33a339c5c08fc38a1fd49ad73e9cc130ceaf5d42
Time: 2014-02-25
Author: rob@luminoso.com
File Name: conceptnet5/builders/json_to_assoc.py
Class Name:
Method Name: convert_to_assoc