From 203212cbb671b2102bcfd17c41a20460f2e26f33 Mon Sep 17 00:00:00 2001 From: nayef211 Date: Tue, 8 Feb 2022 16:13:43 -0800 Subject: [PATCH 1/3] Fixing conll2000chunkingtest --- test/datasets/test_conll2000chunking.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/test/datasets/test_conll2000chunking.py b/test/datasets/test_conll2000chunking.py index ce7de36079..39b3efb63f 100644 --- a/test/datasets/test_conll2000chunking.py +++ b/test/datasets/test_conll2000chunking.py @@ -42,7 +42,7 @@ def _get_mock_dataset(root_dir): # create gz file from dataset folder - compressed_dataset_path = os.path.join(temp_dataset_dir, f"{file_name}.gz") + compressed_dataset_path = os.path.join(base_dir, f"{file_name}.gz") with gzip.open(compressed_dataset_path, "wb") as gz_file, open(txt_file, "rb") as file_in: gz_file.writelines(file_in) From 8d9d5b44df57ac32d52b07729afa9c0ec67a4d5c Mon Sep 17 00:00:00 2001 From: nayef211 Date: Tue, 8 Feb 2022 19:49:06 -0800 Subject: [PATCH 2/3] Fixing style check --- test/datasets/test_conll2000chunking.py | 1 - 1 file changed, 1 deletion(-) diff --git a/test/datasets/test_conll2000chunking.py b/test/datasets/test_conll2000chunking.py index 39b3efb63f..a9e60d51e5 100644 --- a/test/datasets/test_conll2000chunking.py +++ b/test/datasets/test_conll2000chunking.py @@ -27,7 +27,6 @@ def _get_mock_dataset(root_dir): mocked_lines = mocked_data[os.path.splitext(file_name)[0]] with open(txt_file, "w") as f: for i in range(5): - label = seed % 2 rand_strings = [random.choice(string.ascii_letters) for i in range(seed)] rand_label_1 = [random.choice(string.ascii_letters) for i in range(seed)] rand_label_2 = [random.choice(string.ascii_letters) for i in range(seed)] From f85e2b0f23591e16052b28d5ae7a2422ab087a5f Mon Sep 17 00:00:00 2001 From: nayef211 Date: Tue, 8 Feb 2022 20:01:47 -0800 Subject: [PATCH 3/3] style check fixes --- test/datasets/test_conll2000chunking.py | 1 - 1 file changed, 1 deletion(-) diff --git a/test/datasets/test_conll2000chunking.py b/test/datasets/test_conll2000chunking.py index a9e60d51e5..cfbfe730ea 100644 --- a/test/datasets/test_conll2000chunking.py +++ b/test/datasets/test_conll2000chunking.py @@ -39,7 +39,6 @@ def _get_mock_dataset(root_dir): mocked_lines.append(dataset_line) seed += 1 - # create gz file from dataset folder compressed_dataset_path = os.path.join(base_dir, f"{file_name}.gz") with gzip.open(compressed_dataset_path, "wb") as gz_file, open(txt_file, "rb") as file_in: