Created
June 30, 2020 08:17
-
-
Save jaemin93/c4ff91eb9275bce2aef2da6a6a519d3e to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import torch | |
from classification_model import Net | |
from torch.onnx import OperatorExportTypes | |
model = Net() | |
model.eval() | |
x = torch.zeros([1, 1, 28, 28]) | |
print(x.shape) | |
torch.onnx.export(model, x, "test.onnx", verbose=True, operator_export_type=OperatorExportTypes.ONNX) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment