The parameters usually do not depend on the batch size, so you should make sure they have the shape [num_channels]:
norm = nn.GroupNorm(num_groups=3, num_channels=9)
print(norm.weight.shape)
> torch.Size([9])
print(norm.bias.shape)
> torch.Size([9])

Also, note that you are using self.weight and self.bias in your code, which are both set to None, so you might want to change it.