und zwar muss ich dieses Skript für die Uni erstellen: http://www.directupload.net/file/d/5126 ... 8y_jpg.htm
Mein Problem ist das ich nichtsmit Programmieren zu tun habe, und dies eine Übung ist die nur ein Semester dauert wo diese Abgabe über das Bestehen entscheidet.
Ich tue mir sehr schwer damit und brauche wirklich dringend Hilfe.
Was den ersten Schritt, das einlesen betrifft, ist das kein Problem. Das habe ich so gemacht:
Code: Alles auswählen
from scipy.io import wavfile
fs, data = wavfile.read('Spicy_Funk_Cake_snippet.wav')
data = data / data.max()
wavfile.write('output.wav', fs, data)
Code: Alles auswählen
import numpy as np
def splitIntoBlocks (data, blockSize, overlap):
hopSize = blockSize - overlap
n = data.size
nBlocks = int(np.ceil((n - blockSize) / hopSize + 1))
B = np.zeros((nBlocks, blockSize));
for i in range(nBlocks - 1):
B[i,:] = data[i*hopSize : i*hopSize + blockSize]
#letzter block
i = nBlocks - 1;
nLast = data[i*hopSize :].size
B[nBlocks - 1, range(nLast)] = data[i*hopSize :]
return B
Ich bin über jeden Tipp und Ansatz dankbar!
vounesa