Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Adding max pool to Pytorch IMX500 v3 TPC no quantization list #1110

Merged
merged 2 commits into from
Jun 17, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
import torch
from torch import add, sub, mul, div, flatten, reshape, split, unsqueeze, dropout, sigmoid, tanh, chunk, unbind, topk, \
gather, equal, transpose, permute, argmax, squeeze
from torch.nn import Conv2d, Linear, ConvTranspose2d
from torch.nn import Conv2d, Linear, ConvTranspose2d, MaxPool2d
from torch.nn import Dropout, Flatten, Hardtanh, Identity
from torch.nn import ReLU, ReLU6, PReLU, SiLU, Sigmoid, Tanh, Hardswish, LeakyReLU
from torch.nn.functional import relu, relu6, prelu, silu, hardtanh, hardswish, leaky_relu
Expand Down Expand Up @@ -83,7 +83,8 @@ def generate_pytorch_tpc(name: str, tp_model: tp.TargetPlatformModel):
argmax,
gather,
topk,
squeeze])
squeeze,
MaxPool2d])

tp.OperationsSetToLayers("Conv", [Conv2d, ConvTranspose2d],
attr_mapping=pytorch_linear_attr_mapping)
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@
import torch
from torch import add, sub, mul, div, flatten, reshape, split, unsqueeze, dropout, sigmoid, tanh, chunk, unbind, topk, \
gather, equal, transpose, permute, argmax, squeeze
from torch.nn import Conv2d, Linear, ConvTranspose2d
from torch.nn import Conv2d, Linear, ConvTranspose2d, MaxPool2d
from torch.nn import Dropout, Flatten, Hardtanh, Identity
from torch.nn import ReLU, ReLU6, PReLU, SiLU, Sigmoid, Tanh, Hardswish, LeakyReLU
from torch.nn.functional import relu, relu6, prelu, silu, hardtanh, hardswish, leaky_relu
Expand Down Expand Up @@ -82,7 +82,8 @@ def generate_pytorch_tpc(name: str, tp_model: tp.TargetPlatformModel):
argmax,
gather,
topk,
squeeze])
squeeze,
MaxPool2d])

tp.OperationsSetToLayers("Conv", [Conv2d, ConvTranspose2d],
attr_mapping=pytorch_linear_attr_mapping)
Expand Down
Loading