add english speaking tests
This commit is contained in:
parent
06a1514461
commit
28baee85b3
4 changed files with 406 additions and 5 deletions
|
|
@ -12,7 +12,7 @@ def transcribe_file(
|
|||
"""
|
||||
Вызывает recognition.py для одного файла, возвращает транскрипцию.
|
||||
"""
|
||||
cmd = ["python3", str(script_path), "--output", "transcript", str(file_path)]
|
||||
cmd = ["python3", str(script_path), str(file_path)]
|
||||
|
||||
try:
|
||||
result = subprocess.run(
|
||||
|
|
@ -43,7 +43,7 @@ def main():
|
|||
base_dir = Path(
|
||||
r"/mnt/c/proga/projects/ege-skill-dev/.scans/Сложные работы_Английский язык УЧ часть 1/"
|
||||
)
|
||||
regions = ["1-Республика Адыгея"]
|
||||
regions = ["2-Республика Башкортостан", "3-Республика Бурятия"]
|
||||
recognizer_script = Path.home() / ".zeroclaw" / "workspace" / "skills" / "ege-checker" / "recognition.py"
|
||||
|
||||
# Таймаут на транскрипцию одного файла (в секундах)
|
||||
|
|
@ -102,13 +102,12 @@ def main():
|
|||
{
|
||||
"region": region,
|
||||
"fio": fio,
|
||||
"transcript": transcript,
|
||||
"file_path": str(ogg_path),
|
||||
"transcript": transcript
|
||||
}
|
||||
)
|
||||
|
||||
# Сохраняем JSON
|
||||
output_file = Path.cwd() / "transcriptions.json"
|
||||
output_file = Path.cwd() / "tests" / "transcriptions.json"
|
||||
if Path.exists(output_file):
|
||||
with open(output_file, "r", encoding="utf-8") as f:
|
||||
results_to_file: list = json.load(f)
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue