onnx2keras
onnx2keras copied to clipboard
Does it currently support upsample_bilinear?
Code: z = F.upsample(y, size=y.size()[2:], mode='bilinear')
Traceback (most recent call last):
File ".\test.py", line 43, in
Hello @Brave731.
Unfortunately, the converter doesn't support upsample_bilinear
for now due to very different results for the same parameters using PyTorch and Tensorflow.
But you can replace your Bilinear upsample with ConvTranspose2d for example.
@nerox8664 Thanks for your reply, the model can be converted。
How did you convert it successfully? By replacing upsample_bilinear with ConvTranspose2d? @Brave731
@xiaozhi2015 转换后结果不一致
@xiaozhi2015 @Brave731 you may need to fine-tune you model (or at least to train inserted ConvTranspose2d layer) after replacing upsampling method. For some models you will get very similar results, but it depends on your ConvTranspose2d parameters and network architecture.