music_rnn icon indicating copy to clipboard operation
music_rnn copied to clipboard

Upgrade to TensorFlow 1.2.1

Open bzamecnik opened this issue 7 years ago • 0 comments

I wanted to use this model as a baseline for new models - be able to run it and compare against it. Since the project was using old TensorFlow 0.8.0 and that doesn't run on current CUDA toolkit 8 (only up to 7.5) I decided to upgrade to the latest TensorFlow 1.2.1.

Some parts were easily converted automatically using the tf_upgrade.py script. Some changes in RNN API happened between 0.8 and 0.12 so I fixed them manually.

There's one warning left on a deprecated feature:

WARNING:tensorflow:<tensorflow.python.ops.rnn_cell_impl.BasicLSTMCell object at 0x7f80c23b0050>: Using a concatenated state is slower and will soon be deprecated.  Use state_is_tuple=True.

We should change the RNN state representation to some compatible form. So far I only set state_is_tuple=False which matches the old RNN code.

I was able to get it running on CUDA 8 and Tesla K80. One epoch takes around 75 seconds. Is that good?

I tried also to upgrade to Python 3, but python-midi still does not support it. So leaving that for later.

bzamecnik avatar Jul 12 '17 06:07 bzamecnik