-
Notifications
You must be signed in to change notification settings - Fork 127
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
Is your models are deployable in onnx format? #31
Comments
I've tried to export it but there is a mishape error caused by this line https://github.com/saic-vul/ritm_interactive_segmentation/blob/708182de6e3a73da4034579935aef4c19ceae80a/isegm/model/ops.py#L77 |
I had the same issue. but after removing that coords[invalid_points, :, :, :] = 1e6 . i successfully converted and load the onnx model |
but I need you need to set the invalid points |
Hello, i just want to use inference in onnx. So i do some changing in ops.py file
|
Not sure I understood, I advice you to take your time to write a better-explained message. Without the line you have removed, the output shouldn't be the same. |
Is there any updates on this? @Ehteshamciitwah were you able to get a functional ONNX model? |
yes. I changed it successfully to onnx format. During conversion, first, I use else condition making self.cpu_mode=False. https://github.com/saic-vul/ritm_interactive_segmentation/blob/708182de6e3a73da4034579935aef4c19ceae80a/isegm/model/ops.py#L56 After changing, get_coord_features code is:
''' |
Hi, can you provide the code to export onnx? |
Kindly update the code according to your requirements: import torch
def main():
if name == 'main': |
May I ask why the image has 4 channels? Can you send me a copy of the Onnx inference code? |
I modified this code as follows
I found the image_nd is (2,4,256,256) size, but the onnx model input of image is size of (1, 4,height, width). So how to modify this code ? |
I wanted to run these models on some other platforms and needed tha onnx version. Kindly guide me if they are available?
The text was updated successfully, but these errors were encountered: