Solved by Hmrishav_Bandyopadhy in post #3 
              
              
                Hi, 
In case of implementing repetitive blocks, you can set up an entry block and sequential repetitive blocks after the entry block. Implementing it as a module would be : 
class Conv_rep(nn.Module):
      def __init__(self, in_channels, out_channels,num_reps, kernel_size=3, stride=1,
             …