We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1bc2a5c commit 2241c06Copy full SHA for 2241c06
dphon/cli.py
@@ -66,6 +66,7 @@
66
import logging
67
import time
68
import os
69
+import pkg_resources
70
from itertools import combinations
71
from pathlib import Path
72
from typing import Dict
@@ -130,8 +131,9 @@ def run() -> None:
130
131
def setup(args: Dict) -> Language:
132
"""Set up the spaCy processing pipeline."""
133
# get sound table
- sound_table = get_sound_table_json(
134
- Path("./dphon/data/sound_table_v2.json"))
+ v2_path = pkg_resources.resource_filename(
135
+ __package__, "data/sound_table_v2.json")
136
+ sound_table = get_sound_table_json(Path(v2_path))
137
138
# add Doc metadata
139
if not Doc.has_extension("id"):
0 commit comments