model split
2020.07.30 08:15
https://forums.fast.ai/t/pytorch-best-way-to-get-at-intermediate-layers-in-vgg-and-resnet/5707/2
class ResNet50Bottom(nn.Module): def __init__(self, original_model): super(ResNet50Bottom, self).__init__() self.features = nn.Sequential(*list(original_model.children())[:-2]) def forward(self, x): x = self.features(x) return x res50_model = models.resnet50(pretrained=True) res50_conv2 = ResNet50Bottom(res50_model) outputs = res50_conv2(inputs) outputs.data.shape # => torch.Size([4, 2048, 7, 7])
번호 | 제목 | 글쓴이 | 날짜 | 조회 수 |
---|---|---|---|---|
154 | 작전 [4] | WHRIA | 2009.06.23 | 7517 |
153 | 우분투에서 NETBIOS 설정 | WHRIA | 2012.04.02 | 7533 |
152 | Ambition vs Passion | WHRIA | 2007.08.08 | 7585 |
151 | deskzoom | WHRIA | 2012.05.22 | 7606 |
150 | whria.net 홈페이지에 음악 삽입 | WHRIA | 2013.01.17 | 7609 |
149 | whria.net 복구 | WHRIA | 2012.12.09 | 7656 |
148 | gomphoto 1.0.1 | WHRIA | 2013.01.10 | 7662 |
147 | Face It. | WHRIA | 2007.08.09 | 7681 |
146 | Minor update | WHRIA | 2007.08.09 | 7685 |
145 | Interpretation of the Outputs of Deep Learning Model Trained with Skin Cancer Dataset [1] | WHRIA | 2018.06.02 | 7692 |
144 | frame | WHRIA | 2008.12.11 | 7695 |
143 | 추석 | WHRIA | 2007.09.25 | 7702 |
142 | 이랬으면 좋겠네. | WHRIA | 2012.07.15 | 7723 |
141 | 토미그린 (tomygreen) 해외 핸드폰 (nexus 4) 에 설치하기 | WHRIA | 2013.04.03 | 7724 |
140 | Pidgin | WHRIA | 2007.09.01 | 7731 |
https://discuss.pytorch.org/t/how-to-extract-features-of-an-image-from-a-trained-model/119/3