-
Notifications
You must be signed in to change notification settings - Fork 285
Open
Description
I want to ask, if there is any way to suppress a model.
i.e
My model is
class SiameseNetwork(nn.Module):
def __init__(self):
super(SiameseNetwork, self).__init__()
# Setting up the Sequential of CNN Layers
self.model1 = models.resnet50(pretrained=True)
# Defining the fully connected layers
self.fc1 = nn.Sequential(
nn.Linear(1000,2))
def forward_once(self, x):
# Forward pass
output = self.model1(x)
print(self.model1.fc.in_features)
output = self.fc1(output)
return output
def forward(self, input1, input2):
# forward pass of input 1
output1 = self.forward_once(input1)
# forward pass of input 2
output2 = self.forward_once(input2)
return output1, output2
This shows complete ResNet50. Which I do not want. Instead I want a small block saying ResNet50. how can I do this,
Metadata
Metadata
Assignees
Labels
No labels