titu1994 / keras-coordconv

Keras implementation of CoordConv for all Convolution layers
MIT License
148 stars 33 forks source link

"use_radius" is not implemented in "CoordinateChannel3D" #16

Closed DaneshJoy closed 4 years ago

DaneshJoy commented 4 years ago

Thanks for sharing your code 👍 There is a usage of __use_radius argument in the call function for rank=2__:

if self.use_radius:
    rr = K.sqrt(K.square(xx_channels - 0.5) +
    K.square(yy_channels - 0.5))
    outputs = K.concatenate([outputs, rr], axis=-1)

Is it possible to use the same action for rank=3 ?

There is a definition for this argument in the docstring of the CoordinateChannel3D, which I assume that is copied from the CoordinateChannel2D:

use_radius: Boolean flag to determine whether the
            radius coordinate should be added for 2D rank
            inputs or not.
titu1994 commented 4 years ago

Use radius is supported only on 2d coordconv. That doc should be updated.

DaneshJoy commented 4 years ago

Thanks, and Good Luck!