MCPcopy Create free account
hub / github.com/google-research/language / resplit_ct

Function resplit_ct

language/orqa/preprocessing/create_data_splits.py:87–101  ·  view source on GitHub ↗

Resplit the CuratedTrec dataset.

()

Source from the content-addressed store, hash-verified

85
86
87def resplit_ct():
88 """Resplit the CuratedTrec dataset."""
89 hash_fn = make_hash_fn()
90 resplit_data(
91 input_path=FLAGS.ct_train_path,
92 output_path=get_resplit_path("CuratedTrec", "train"),
93 keep_fn=lambda x: hash_fn(x) != 0)
94 resplit_data(
95 input_path=FLAGS.ct_train_path,
96 output_path=get_resplit_path("CuratedTrec", "dev"),
97 keep_fn=lambda x: hash_fn(x) == 0)
98 resplit_data(
99 input_path=FLAGS.ct_test_path,
100 output_path=get_resplit_path("CuratedTrec", "test"),
101 keep_fn=lambda x: True)
102
103
104def make_hash_fn():

Callers 1

mainFunction · 0.85

Calls 3

make_hash_fnFunction · 0.85
resplit_dataFunction · 0.85
get_resplit_pathFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…