Skip to content
This repository has been archived by the owner on Oct 13, 2022. It is now read-only.

Piotr's fix to how we call Lhotse #8

Merged
merged 3 commits into from
Nov 13, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 3 additions & 2 deletions egs/librispeech/asr/simple_v1/prepare.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
# Copyright (c) 2020 Xiaomi Corporation (authors: Junbo Zhang, Haowen Qiu)
# Apache 2.0

import multiprocessing
import os
from concurrent.futures import ProcessPoolExecutor
from pathlib import Path
Expand Down Expand Up @@ -39,8 +40,8 @@

for partition, manifests in librispeech_manifests.items():
print(partition)
with LilcomFilesWriter(f'{output_dir}/feats_{partition}'
) as storage, ProcessPoolExecutor(num_jobs) as ex:
with LilcomFilesWriter(f'{output_dir}/feats_{partition}') as storage, \
ProcessPoolExecutor(num_jobs, mp_context=multiprocessing.get_context("spawn")) as ex:
cut_set = CutSet.from_manifests(
recordings=manifests['recordings'],
supervisions=manifests['supervisions']).compute_and_store_features(
Expand Down