From: Mart Lubbers Date: Wed, 31 May 2017 07:57:41 +0000 (+0200) Subject: add alien data X-Git-Url: https://git.martlubbers.net/?a=commitdiff_plain;h=76861bac7fe18c5408be0f3b121387d867ce8d1f;p=asr1617data.git add alien data --- diff --git a/orig/alien/01 - Consigned to Flames of War.flac b/orig/alien/01 - Consigned to Flames of War.flac new file mode 100644 index 0000000..13241ff Binary files /dev/null and b/orig/alien/01 - Consigned to Flames of War.flac differ diff --git a/orig/alien/01 - Hatred.flac b/orig/alien/01 - Hatred.flac new file mode 100644 index 0000000..2b23711 Binary files /dev/null and b/orig/alien/01 - Hatred.flac differ diff --git a/predict.py b/predict.py index 45e94da..de1abc2 100644 --- a/predict.py +++ b/predict.py @@ -38,14 +38,13 @@ tier = tgob.add_tier('lyrics') window_len = int(1.0/winstep) x = model.predict(data, batch_size=32, verbose=0) -s = np.r_[x[window_len-1:0:-1],x,x[-2:-window_len-1:-1]] -w = np.hanning(window_len) - -smoothed = np.convolve(w/w.sum(), s[:,0], mode='valid') - -wavdata = np.uint8(list(map(int, - smoothed*255))[int(window_len/2):-1*(int(window_len/2))]) - +#s = np.r_[x[window_len-1:0:-1],x,x[-2:-window_len-1:-1]] +#w = np.hanning(window_len) +# +#smoothed = np.convolve(w/w.sum(), s[:,0], mode='valid') +#wavdata = np.uint8(list(map(int, +# smoothed*255))[int(window_len/2):-1*(int(window_len/2))]) +wavdata = np.uint8(x*255) print('sr: ', int(1.0/winstep)) print("len(wavdata): ", len(wavdata))