That’s an interesting approach!
Based on this, you could also create a “hook class” holding this internal parameter, which could be simpler than creating new modules:
class ActivationHook():
    def __init__(self, name, every_steps=1):
        self.name = name
        self.every_steps = every_steps
        self.steps = 0
        self.activation = {}
    
    def hook(self, model, input, output):
        if (self.steps % self.every_steps) == 0:
            self.activation[self.name] = output.detach()
        self.steps += 1
    

model = MyModel()
act_hook = ActivationHook('fc2', every_steps=2)
model.fc2.register_forward_hook(act_hook.hook)
x = torch.randn(1, 25)
output = model(x)
print(act_hook.activation['fc2'])