Fixes to filter_clips_hifreq
This commit is contained in:
parent
a367ea3fda
commit
9b693b0a54
|
@ -17,7 +17,8 @@ def filter_no_hifreq_data(path, output_path):
|
|||
return
|
||||
stft = get_spec_mags(clip)
|
||||
if stft.mean() < .08:
|
||||
print(f"Ignore {path}")
|
||||
with open(output_path, 'a') as o:
|
||||
o.write(f'{path}\n')
|
||||
|
||||
if __name__ == '__main__':
|
||||
do_to_files(filter_no_hifreq_data)
|
|
@ -30,7 +30,6 @@ def do_to_files(process_file_fn):
|
|||
resume = args.resume
|
||||
num_workers = int(args.num_workers)
|
||||
|
||||
os.makedirs(out, exist_ok=True)
|
||||
path = pathlib.Path(src)
|
||||
files = path.rglob(glob)
|
||||
files = [str(f) for f in files]
|
||||
|
|
Loading…
Reference in New Issue
Block a user