def create_metanet(self): metanet = MetaWideResNet(num_classes=params.n_classes, depth=params.depth, widen_factor=params.widen_factor).to(self.device) metanet.load_state_dict(self.model.state_dict()) meta_sgd = MetaSGD(metanet, **self.params.meta_optim) return metanet, meta_sgd
def create_metanet(self): metanet = MetaLeNet(params.n_classes, with_fc=True).to(self.device) metanet.load_state_dict(self.model.state_dict()) meta_sgd = MetaSGD(metanet, **self.params.meta_optim) return metanet, meta_sgd