imalikshake / StyleNet

A cute multi-layer LSTM that can perform like a human 🎶
190 stars 39 forks source link

Reshape batch data in data_util #3

Open jenchen1398 opened 5 years ago

jenchen1398 commented 5 years ago

After quantizing and converting midi files to npy using generate_audio.ipynb, I try to start training but data_utils cannot reshape my data into the appropriate shape for training. I believe that data_util.pad() is trying to reshape the data into a much larger dimension than possible. How do I fix this issue?

File ".StyleNet/data_util.py", line 43, in batch input_batch, output_batch, seq_len = self.pad(input_batch, output_batch) File ".StyleNet/data_util.py", line 96, in pad sequence_X = np.reshape(sequence_X, [int(current_batch*mini_batches), int(max_lens), self.input_size]) ValueError: cannot reshape array of size 43400 into shape (217,200,176)

v14sta commented 3 years ago

After quantizing and converting midi files to npy using generate_audio.ipynb, I try to start training but data_utils cannot reshape my data into the appropriate shape for training. I believe that data_util.pad() is trying to reshape the data into a much larger dimension than possible. How do I fix this issue?

File ".StyleNet/data_util.py", line 43, in batch input_batch, output_batch, seq_len = self.pad(input_batch, output_batch) File ".StyleNet/data_util.py", line 96, in pad sequence_X = np.reshape(sequence_X, [int(current_batch*mini_batches), int(max_lens), self.input_size]) ValueError: cannot reshape array of size 43400 into shape (217,200,176)

dear Ms. jen i actually have the same problem but the problem is that since it has written in py 2.7 now I cannot run the script because the tensorflow does not support and i dont know how to run it , in colab or virtualenv? i hope you could guide me