Saving feature extractor model

When I try to do this:

effnet = models.efficientnet_b0(pretrained=True)
effnet = create_feature_extractor(effnet, return_nodes=['features.7.0.block.3.1'])
torch.save(effnet, 'effnet.pth')

I get RecursionError: maximum recursion depth exceeded

It’s a bug or I shouldn’t do that?

I don’t know if saving a feature extractor is supported, but would assume to see a proper error message instead of a RecursionError. Could you create an issue on GitHub so that we could track it there, please?