MCPcopy Create free account
hub / github.com/PaddlePaddle/Research / _map

Method _map

NLP/Text2SQL-BASELINE/text2sql/utils/dusql_evaluation.py:911–921  ·  view source on GitHub ↗

map

(self, schema)

Source from the content-addressed store, hash-verified

909 return dct_table2cols
910
911 def _map(self, schema):
912 """map"""
913 id_map = {'*': "__all__"}
914 for key, vals in schema.items():
915 for val in vals:
916 id_map[key.lower() + "." + val.lower()] = "__" + key.lower() + "." + val.lower() + "__"
917
918 for key in schema:
919 id_map[key.lower()] = "__" + key.lower() + "__"
920
921 return id_map
922
923
924def get_scores(count, pred_total, gold_total):

Callers 1

__init__Method · 0.95

Calls 1

itemsMethod · 0.80

Tested by

no test coverage detected