maybe remedy an issue that crops up if you have a non-wav and non-json file in a results folder (assuming)
This commit is contained in:
parent
b64948d966
commit
797882336b
|
@ -220,9 +220,9 @@ def generate(**kwargs):
|
||||||
if extension != ".json" and extension != ".wav":
|
if extension != ".json" and extension != ".wav":
|
||||||
continue
|
continue
|
||||||
match = re.findall(rf"^{voice}_(\d+)(?:.+?)?{extension}$", filename)
|
match = re.findall(rf"^{voice}_(\d+)(?:.+?)?{extension}$", filename)
|
||||||
|
if match and len(match) > 0:
|
||||||
key = int(match[0])
|
key = int(match[0])
|
||||||
idx_cache[key] = True
|
idx_cache[key] = True
|
||||||
|
|
||||||
if len(idx_cache) > 0:
|
if len(idx_cache) > 0:
|
||||||
keys = sorted(list(idx_cache.keys()))
|
keys = sorted(list(idx_cache.keys()))
|
||||||
|
|
Loading…
Reference in New Issue
Block a user