I am currently implementing residual connection on my architecture. I found codes that use .clone() at a junction. But, will I have a problem if I don’t use .clone() for skip connection?
This is the simplified code of my model.
def forward(self, input):
out = self.conv1(input)
out = self.BatchNorm1(out)
out = self.ReLU(out)
out = self.conv2(out)
out = self.BatchNorm1(out)
residual_output = input + out