TypeError: Input 'split_dim' of 'Split' Op has type float32 that does not match expected type of int32
I am trying to convert a caffemodel to tensorflow and I am getting this error. Could anyone please help me out.
Traceback (most recent call last):
File "convert.py", line 130, in
I ran into this problem myself and resolved this by reading this post and following their advice - https://github.com/tensorflow/models/issues/933. Basically there are some tensorflow API changes (https://github.com/tensorflow/tensorflow/blob/master/RELEASE.md) and you might have to manually reverse the order of the arguments for "split" in network.py. It worked for me.
To add to hainingren's answer, update the following lines in kaffe/tensorflow/network.py to reflect the changes in tensorflow:
input_groups = tf.split(3, group, input)
kernel_groups = tf.split(3, group, kernel)
output_groups = [convolve(i, k) for i, k in zip(input_groups, kernel_groups)]
# Concatenate the groups
output = tf.concat(3, output_groups)
to
input_groups = tf.split(input, group, 3)
kernel_groups = tf.split(kernel, group, 3)
output_groups = [convolve(i, k) for i, k in zip(input_groups, kernel_groups)]
# Concatenate the groups
output = tf.concat(output_groups, 3)