Error Running Keras Neural Machine Translation Example

Hi,
I just setup my KNIME environment according to the instructions. For now , I just have CPU version. When I run the “DL Python Network Creator” it gives the following error:
“tensorflow.python.framework.errors_impl.NotFoundError: Op type not registered ‘CudnnRNN’ in binary running on KASERVER. Make sure the Op and Kernel are registered in the binary running in this process.”

The MNIST Example however runs fine. I’m not sure if I missed something in the setup process.
Attached is the KNIME log file for more details. Any help appreciated.

Thanks !

knime_nmt_error_log.txt (7.6 KB)

Hi mohammedayub,

oh, this is my fault.
I created the example on a computer with a GPU and used the specialized CuDNN RNN layers for performance reasons which are unfortunately not supported on CPU.
We will update the workflow with a network that supports CPU in the near future.
I will keep you posted.

If you want to use the example before this is done, you can simply replace all occurrences of CuDNNLSTM with normal LSTM in the Python Network Creator.

I am really sorry for the inconvenience.

Have a great sunday,

nemad

Hi Nemad,
Not a problem. Now I understand better.
I will try replacing the functions and run again.
Thanks !

Mohammed Ayub

Hi Nemad,

I’m having trouble running the example just with LSTM on CPU. I successfully ran the “DL Python Network Creator” by simply changing the function calls from CuDNNRNN to LSTM(…). I get error while running “DL Python Network Learner”…Attached is the error log for more info.

knime_nmt_error_log2.txt (8.3 KB)

Hi Nemad,

Any update on this ?

Hi mohammedayub,

I get the same error but I haven’t found the cause yet.
This seems to be a Keras issue because according to the documentation it shouldn’t make a large difference whether one uses LSTM vs. CuDNNLSTM but apparently it does.
I’ll report back once I found a solution.

I did some digging and it seems like this is an issue with Keras.
For some reason, the gradients are None for the encoder network’s LSTM.
I opened a corresponding issue on the Keras GitHub page and we will have to wait and see if they have a solution to the problem.
I am also working on a workaround and will inform you once it is available.

Cheers,

nemad

Thanks a lot Nemad. Appreciate it. Looking forward to your solution.

We just updated the example workflow.
It now supports execution with CPU.
Unfortunately, the python code got slightly more complicated because I had to work around the issue mentioned above.

It worked like a charm. Thanks for your Help Nemad.

1 Like

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.