I cannot reproduce the increasing feature shape using a simple code snippet:
model = models.detection.keypointrcnn_resnet50_fpn()
model.eval()
x = [torch.randn(3, 224, 224), torch.randn(3, 256, 256)]

all_features = []
def get_layer(module, x):
    all_features.append(x)

for name, m in model.named_modules():
    if name == 'rpn.head':
        model.register_forward_pre_hook(get_layer)

out = model(x)
print([f[0][0].shape for f in all_features])

So unsure what’s causing the issue. Your current code is a bit hard to read and you can post code snippets by wrapping them into three backticks ```, which would make debugging easier.
Note that you are not detaching the activations before storing them in the list, which would thus store the entire computation graph and all intermediate activations with it unless you either detach() the tensor or wrap the forward pass into a with torch.no_grad() guard (which will disallow the gradient computation).