i got error Error using wavread (line 67) Invalid Wave File. Reason: Cannot open file.
Error in energy_per_frame (line 2) [inpu fs] = wavread(file);
this is the source code for function that call energy_per_frame.
[inpu fs] = wavread(file); clc;clear;close all; file = input('Enter name of wav file ', 's'); counter=0; for test_number = 0:4 for test_number2 = 0:20 counter=counter+1; reference = dtw_avg(test_number2); test = energy_per_frame(file); distance(counter) = dtw(test,reference); end
This is source code for function energy_per_frame
[inpu fs] = wavread(file); fn = fs/2; bins = 512; %useable bins frame_length = bins; window = hamming(frame_length); overlap = .5; number_of_frames = (length(inpu)/(frame_length)/overlap) - 1;
What is wrong here?