Need for unfreeze_to function similar to freeze_to function


I have a model and it is composed of two parts. The first part is a DCGAN architecture, randomly initialized by me, and the second part is a pre-trained Image Recognition model (something like resnet52). I have joined these two parts in a nn.Module class. What I want to do is to freeze the resent52 part and just train the DCGAN one. Here is my sample code.

class Test(nn.Module):
  def __init__(self, dis):
    # define generator here
    self.gen = Generator()
    # use the pretrained classifier
    self.dis = dis
  def forward(self, input):
    return ...

I would like to know how is it possible?