How can I change layer's output shape of keras-pretrained-model

Viewed 105

I'm using Pretrained Model of Segmentation Models(https://github.com/qubvel/segmentation_models)

But I want to change first Conv2d layer's parameters to change image size.

I can change parameters simple code like below.

##base_model is segmentaion_models.Unet('efficientnetb2', input_size=(800,800))

base_model.layer[1].strides = (4,4) # before : (2,2)

and I can check changed value

base_model.layer[1].strides
> (4,4)

But output shape is same nevertheless change strides value

base_model.layers[1].get_out_shape_at(0)
> (None, 400, 400, 32) 

I expected that outshape value is "(None, 200, 200, 32)" because strides value was changed. But isn't

My questions are these :

  1. Why output shape's value isn't change?
  2. Is there any action I need to change output shape?
  3. Is there no correlation strides and output shape?

Thanks

0 Answers
Related