Zardinality / TF-deformable-conv

Implementation of deformable convolution as an operation in tensorflow

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

deform_conv_2d() meet the error

FakerYFX opened this issue · comments

when i build my own model,in this step:
image

image
image
i meet the errror:
image
look forward to hearing from you.
@Zardinality

you feed a NHWC format data into the layer of NCHW. its not related to this repo

i use this img = tf.transpose(img, [0, 3, 1, 2]) to change to the NCHW,but i got another errror:
image
@Zardinality

Before using deform_conv_2d(),convert the input format to NCHW:tf.transpose(img, [0, 3, 1, 2]);
And convert the function output to NHWC:tf.transpose(img, [0, 2, 3, 1]).

commented

I meet the same issue, and I found the arg data_format of deform_conv_op is useless.
Only make sure input a tensor with NCHW can the op data_format work.