DPT icon indicating copy to clipboard operation
DPT copied to clipboard

.ONNX models

Open GeorgeAdamon opened this issue 4 years ago • 9 comments

Hello,

are there any plans to provide the pre-trained models in .onnx format ?

Thank you!

GeorgeAdamon avatar Jun 06 '21 15:06 GeorgeAdamon

Thanks for the request, we've noted it and plan to provide this eventually. It might take some time as the current implementation doesn't play well with jit/onnx exporters and it seems that we would need a partial rewrite of the model.

ranftlr avatar Jun 08 '21 09:06 ranftlr

Thanks a lot @ranftlr , good to know. I had trouble trying to convert it using the common torch.onnx workflow.

GeorgeAdamon avatar Jun 08 '21 10:06 GeorgeAdamon

Thanks a lot @ranftlr , good to know. I had trouble trying to convert it using the common torch.onnx workflow.

Hello,Has this problem been solved?

Wing100 avatar Oct 15 '21 14:10 Wing100

Thanks for the request, we've noted it and plan to provide this eventually. It might take some time as the current implementation doesn't play well with jit/onnx exporters and it seems that we would need a partial rewrite of the model.

Hello,I also encountered the same problem. Has this problem been solved, please?

Wing100 avatar Oct 15 '21 14:10 Wing100

Hi @ranftlr , if you have suggestions regarding the required changes then please do tell. I wish to export it into an onnx file.

romil611 avatar Oct 21 '21 07:10 romil611

Would also love to have them in onnx files

wtesler avatar Dec 25 '21 11:12 wtesler

I was able to do that by changing the unflatten function used in dpt/vit.py file to view.

romil611 avatar Dec 27 '21 08:12 romil611

Hi @romil611 Are you saying that you successfully created an onnx file from this model? If so, is there a possibility to share it here? I would love to try it out and it's difficult for me to manually update the model.

wtesler avatar Dec 27 '21 19:12 wtesler

@wtesler I ran into some issues(#57 ) so I stopped using this model. Currently I don't have the files.

romil611 avatar Dec 27 '21 22:12 romil611