Course 4 Week 3 U-net model

With the U-net model I keep getting the error:
ValueError: A Concatenate layer requires inputs with matching shapes except for the concat axis. Got inputs shapes: [(None, 6, 8, 256), (None, 12, 16, 256)]

Any pointers in the right direction are much appreciated!

Hey @eyadsaid, you are not multiplying the n_filters.

1 Like

And also, @eyadsaid , sharing solution code is against the honour code. Please only share your errors. If the solution code needs to be looked at, staff or the mentors will ask you to DM you it.

I’m removing the solution code from your post.

1 Like

For some reason when I copied the lines the * did not appear but I do have it in my solution.

I apologize, but in many different posts I saw others sharing parts of the code and I thought a partial copy is acceptable. I will be more careful in the future.

1 Like

Hey @eyadsaid. Did this help or are you still stuck here ?

I’m afraid not, like I mentioned in my reply to your suggestion, I am indeed multiplying the filters.

Could you DM your notebook ? I’ll take a look. Thanks.

I found my mistake after @Mubsi valuable help. I had max_pooling = ‘False’. (should not have used ’ ')
This caused the different dimensions.

1 Like