# Invalid input configuration for kernel height

**URL:** https://community.konduit.ai/t/invalid-input-configuration-for-kernel-height/1132
**Category:** DL4J
**Created:** [January 27, 2021, 5:01pm UTC](https://community.konduit.ai/t/invalid-input-configuration-for-kernel-height/1132 "2021-01-27T17:01:21Z")
**Posts on this page:** 2
**Page:** 1

<div class="post-metadata">

### Author: ![FanDev](https://yyz1.discourse-cdn.com/flex035/user_avatar/community.konduit.ai/fandev/32/231_2.png) [@FanDev](https://community.konduit.ai/u/FanDev)
#### Post date: [January 27, 2021, 5:01pm UTC](https://community.konduit.ai/t/invalid-input-configuration-for-kernel-height/1132/1 "2021-01-27T17:01:21Z")

</div>

I know someone had this issue before because their image size is too small to fit in a filter.

In my case, I can use the exact same model in python without any issue (Python 3.8 & Tensoflow 2.2.0 & Keras 2.4.3. But I see the error message when import into DL4J. Is there any version difference to cause the issue? This model contains several _dilated convolution with a large dilation factor_, The implementation is the same Conv3D with parameter dilate=1,2,4,8, etc…

org.deeplearning4j.exception.DL4JInvalidConfigException: Invalid configuration for layer (idx=-1, name=conv3d\_16, type=Convolution3DLayer) for height dimension: Invalid input configuration for kernel height. Require 0 \< kH \<= inHeight + 2\*padH; got (kH=17, inHeight=16, padH=0)

Input type = InputTypeConvolutional3D(format=NCDHW,d=16,h=16,w=16,c=128), kernel = [3, 3, 3], strides = [1, 1, 1], padding = [0, 0, 0], layer size (output channels) = 128, convolution mode = Same

Thanks.

---

<div class="post-metadata">

### Author: ![agibsonccc](https://yyz1.discourse-cdn.com/flex035/user_avatar/community.konduit.ai/agibsonccc/32/697_2.png) [@agibsonccc](https://community.konduit.ai/u/agibsonccc)
#### Post date: [January 29, 2021, 1:33am UTC](https://community.konduit.ai/t/invalid-input-configuration-for-kernel-height/1132/2 "2021-01-29T01:33:30Z")

</div>

> [@FanDev](#):
>
> port into DL4J. Is there any version difference to cause the issue? This model contains several _dilated convolution with a large dilation factor_ , The implementation is the same Conv3D with parameter dil

@FanDev could you specify how you’re building the model? Are you using model import? Any code we can run would help.
