jtkim-kaist / VAD

Voice activity detection (VAD) toolkit including DNN, bDNN, LSTM and ACAM based VAD. We also provide our directly recorded dataset.
834 stars 232 forks source link

IndexError: list index out of range #5

Closed tydusky closed 6 years ago

tydusky commented 6 years ago

When I running the 'main.m' on Matlab, an error occurs:

Traceback (most recent call last):
  File "/Users/tianyu/Documents/MATLAB/VAD-master/lib/python/VAD_test.py", line 102, in <module>
    pred, label = graph_test.do_test(graph_list[-1], data_dir, norm_dir, data_len, is_default, mode)
IndexError: list index out of range

Then I try to debug the 'VAD_test.py' with PyCharm:

Traceback (most recent call last):
  File "/Users/tianyu/Documents/MATLAB/VAD-master/lib/python/VAD_test.py", line 102, in <module>
    pred, label = graph_test.do_test(graph_list[-1], data_dir, norm_dir, data_len, is_default, mode)
  File "/Users/tianyu/Documents/MATLAB/VAD-master/lib/python/graph_test.py", line 195, in do_test
    valid_inputs, valid_labels = valid_data_set.next_batch(valid_batch_size)
  File "/Users/tianyu/Documents/MATLAB/VAD-master/lib/python/data_reader_DNN_v2.py", line 81, in next_batch
    self._input_spec_list[self._num_file]), batch_size, self._w)
IndexError: list index out of range

I find the 'self._input_spec_list' is empty, and it may be caused by this: self._input_spec_list = sorted(glob.glob(input_dir+'/*.txt')) I don't find any '.txt' file exist in the project, is it missing?

jtkim-kaist commented 6 years ago

That error maybe from mrcg_extract.m function. mrcg_extract function automatically make that txt file please verify your mrcg extraction was correctly done. Thank you.

tydusky commented 6 years ago

Thanks for your help. It seems that there is something wrong with the directory of the generated txt file, and now it works.

shimoli15 commented 6 years ago

@zjradty : Can you please tell what helped you resolve the issue? I am facing the same problem now.

Thanks.