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

Mobilesam model experiences a large number of operator overflows during inference on the RK3588, which is completely different from the behavior observed in the simulator. #346

Open
MiningIrving opened this issue Nov 15, 2024 · 0 comments

Comments

@MiningIrving
Copy link

The official provided an example for mobilesam, but I noticed that its img_size is 448, while the original mobilesam model has an image size of 1024. The iou of the provided example is only 0.137, while the original model has an iou of 0.49. I want to use the original model for inference, but after converting the encoder, I found that the output is completely incorrect. After analyzing the board using adb, I discovered that several operators overflowed, which caused the final output to be abnormal.
image

How should I resolve these overflows? After reducing the matrix size, I found that some operators were converted to exSDPAttention, which prevents overflows. I'm not sure why this happens. Could you tell me under what conditions the conversion occurs, or if I can solve the overflow issue by manipulating the operators?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant