quantized fuse_model should have an inplace argument
Open
@raghuramank100 is already working on this.
Since Nov 12, 2019.
module: models.quantization
- Dominant language
- Python
- Stars
- 17.9k
- Forks
- 7.3k
- Avg merge
- 1d 15h
- Merged PRs (30d)
- 13
Description
Currently if the user wants to have the fused model while preserving the original, they have to do
import copy
import torchvision.models.quantization as models
model = models.resnet18(pretrained=True, progress=True, quantize=False)
model_fused = copy.deepcopy(model)
model_fused.fuse_model()
Given that the quantization API provides an inplace variant for the torch.quantization.fuse_modules, we need to have an option for inplace in the model methods as well.
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.