Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Avletters #1

Open
wants to merge 9 commits into
base: master
Choose a base branch
from
12 changes: 12 additions & 0 deletions pyVSR/avletters/import_data.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
#!/bin/bash
#this is not guarded against whitespace!
src_dir=/data/corpora/audiovisual/avletters
#import audio data as is with sub directories
mkdir data
ln -s $src_dir/Audio data/
#import video data with name change, dropping "-lips" from "xxx-lips.mat"
mkdir data/Lips
for f in $src_dir/Lips/*.mat; do ln -s $f data/Lips/$(basename ${f/-lips/}); done
#make labels from the file name, this is just the first letter
mkdir data/Label
for f in data/Audio/mfcc/Clean/*.mfcc; do name=$(basename $f ".mfcc"); echo $name ${name/[0-9]_*} > data/Label/$name.mlf; done
Copy link
Owner

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The bash scripts wouldn't play nice on Windows platforms. This one seems easy to port.

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

probably just as fast to put it in a python script that runs anywhere

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

weird, should be "data/Label/$name.lab"