Different weight initilization for each dense block, densenet121

[I can not seem to find a way to initialize weights for different dense blocks.
I am using for name,layer in model.named_modules() for accessing layers.I initialize weights of ‘feature.denseblock2’ by a custom weight and rest by Xavier initialization.
the issue is the layers in each dense block goes to Xavier initialization as the it loops through named_modules.
return_node.keys() = ‘feature.denseblock2’

Screenshot from 2022-12-02 13-02-11