Skip to content

Commit

Permalink
Fix test path
Browse files Browse the repository at this point in the history
  • Loading branch information
endast committed May 7, 2024
1 parent 9c718f7 commit 2ceabb5
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions tests/deeprvat/test_train.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,6 @@
from deeprvat.data import DenseGTDataset
import yaml
from typing import Dict, Tuple
import pandas as pd
import itertools
from torch.utils.data import DataLoader
from tqdm import tqdm
Expand Down Expand Up @@ -36,10 +35,12 @@
# 9. Different min_variant_counts

script_dir = Path(__file__).resolve().parent
repo_base_dir = script_dir.parent.parent
tests_data_dir = script_dir / "test_data" / "training"
example_data_dir = script_dir.parent / "example"
test_config_file = tests_data_dir / "config.yaml"


with open(tests_data_dir / "phenotypes.txt", "r") as f:
phenotypes = f.read().strip().split("\n")

Expand Down Expand Up @@ -127,7 +128,7 @@ def test_multiphenodataset(multipheno_data, cache_tensors: bool, batch_size: int
list(zip(phenotypes, [0, 1, 2])),
)
def test_make_dataset(phenotype: str, min_variant_count: int, tmp_path: Path):
# os.chdir(example_data_dir)
os.chdir(repo_base_dir)

with open(test_config_file, "r") as f:
config = yaml.safe_load(f)
Expand Down

0 comments on commit 2ceabb5

Please sign in to comment.