Skip to content

Commit

Permalink
typo
Browse files Browse the repository at this point in the history
  • Loading branch information
renqianluo committed Apr 3, 2023
1 parent f9641fb commit a27f7d5
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 11 deletions.
10 changes: 2 additions & 8 deletions examples/QA-PubMedQA/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -3,13 +3,7 @@
## Data
Download data from [PubMedQA](https://github.com/pubmedqa/pubmedqa) and following the steps of splitting dataset.

Copy the files `pqal_fold0/train_set.json`, `pqal_fold0/dev_set.json`, `test_set.json` and `test_ground_truth.json` to `../../../data/PubMedQA/raw` and rename them:

``` bash
mv train_set.json pqal_train_set.json
mv dev_set.json pqal_dev_set.json
mv test_set.json pqal_test_set.json
```
Copy the files `pqal_fold0/train_set.json`, `pqal_fold0/dev_set.json`, `test_set.json` and `test_ground_truth.json` to `../../data/PubMedQA/raw`

Then, you can process the data by:
``` bash
Expand All @@ -22,7 +16,7 @@ bash preprocess_large.sh # for BioGPT-Large


## Model Checkpoint
We provide our fine-tuned model on the task. See [here](../../../README.md#pre-trained-models)
We provide our fine-tuned model on the task. See [here](../../README.md#pre-trained-models)

## Inference and Evaluating
You can inference and evaluate the model on the test set by:
Expand Down
6 changes: 3 additions & 3 deletions examples/QA-PubMedQA/rebuild_data.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,6 +77,6 @@ def worker(fname, prefix, fn):
dumper(ret, prefix)


worker(os.path.join(f"{data_dir}", "pqal_train_set.json"), os.path.join(f"{data_dir}", f"{prefix}_train"), build_target_seq)
worker(os.path.join(f"{data_dir}", "pqal_dev_set.json"), os.path.join(f"{data_dir}", f"{prefix}_valid"), build_target_seq)
worker(os.path.join(f"{data_dir}", "pqal_test_set.json"), os.path.join(f"{data_dir}", f"{prefix}_test"), build_target_seq)
worker(os.path.join(f"{data_dir}", "train_set.json"), os.path.join(f"{data_dir}", f"{prefix}_train"), build_target_seq)
worker(os.path.join(f"{data_dir}", "dev_set.json"), os.path.join(f"{data_dir}", f"{prefix}_valid"), build_target_seq)
worker(os.path.join(f"{data_dir}", "test_set.json"), os.path.join(f"{data_dir}", f"{prefix}_test"), build_target_seq)

0 comments on commit a27f7d5

Please sign in to comment.