I’ve discovered that issue when I was trying to understand why does my quantized version of EfficientNet-b4 work slower than the float one.
I use torch 1.6.0, fbgemm default config (torch.quantization.get_default_qconfig('fbgemm'))
torchprof library shows that _depthwise_conv in blocks 2, 6, 10, 22 are the key problem: they are 3-10 times slower than in float model!
These layers differ from others only with (2, 2) stride instead of (1,1), (3,3), (5,5). I do not give the full list of hassle-free layers in the screenshot, but I’ve checked that
Is this the expected behavior? What could be the reason?
stride_issue1201×1130 143 KB