Skip to content

Commit

Permalink
Fix test_ranking_deezy_on_the_fly
Browse files Browse the repository at this point in the history
  • Loading branch information
thobson88 committed Oct 24, 2024
1 parent 85f229d commit 73ced03
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion tests/test_ranking.py
Original file line number Diff line number Diff line change
Expand Up @@ -128,7 +128,7 @@ def test_ranking_deezy_on_the_fly(tmp_path):
},
deezy_parameters={
# Paths and filenames of DeezyMatch models and data:
"dm_path": os.path.join(current_dir,"sample_files/resources/deezymatch/"),
"dm_path": os.path.join(current_dir, "../resources/deezymatch/"),
"dm_cands": "wkdtalts",
"dm_model": "w2v_ocr",
"dm_output": "deezymatch_on_the_fly",
Expand All @@ -142,6 +142,7 @@ def test_ranking_deezy_on_the_fly(tmp_path):
"overwrite_training": False,
"do_test": False,
},
already_collected_cands=dict(),
)

# Test that perfect_match acts before deezy
Expand All @@ -152,6 +153,7 @@ def test_ranking_deezy_on_the_fly(tmp_path):
# Test that deezy works
myranker.already_collected_cands = {}
candidates, already_collected_cands = myranker.deezy_on_the_fly(["Ashton-cnderLyne"])

assert (0.0 < candidates["Ashton-cnderLyne"]["Ashton-under-Lyne"] < 1.0)

@pytest.mark.skip(reason="Needs deezy model")
Expand Down Expand Up @@ -187,6 +189,7 @@ def test_ranking_find_candidates(tmp_path):
"overwrite_training": False,
"do_test": True,
},
already_collected_cands=dict(),
)

# Test that perfect_match acts before deezy
Expand Down

0 comments on commit 73ced03

Please sign in to comment.