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

Decoder CoreML running time problem #19

Open
benjamin-kramer opened this issue Jan 21, 2024 · 2 comments
Open

Decoder CoreML running time problem #19

benjamin-kramer opened this issue Jan 21, 2024 · 2 comments

Comments

@benjamin-kramer
Copy link

benjamin-kramer commented Jan 21, 2024

When running the decoder with the same number of points time after time, the running time may approach the number reported by the performance analysis of Xcode. However, this is not the usual use case of this model.
Usually, one would select points iteratively, such that the size of the model input constantly changes (first 256x64x64, 1x1x2, 1x1, than 256x64x64, 1x2x2, 1x2 and so on).
Every time the model is used with a different size, some internal CoreML state is discarded, and the running time is that of a first-run (which is ~10x slower!).

If the model can be designed such that it is constantly run with the same number of points (16), with some of the points being ignored, perhaps it could help resolve this issue (but I really have no idea if that's possible).

@benjamin-kramer benjamin-kramer changed the title CoreML running time problem Decoder CoreML running time problem Jan 21, 2024
@benjamin-kramer
Copy link
Author

Note - Running the model with CPU+ANE (instead of .all compute units, which defaults to GPU and ANE) improves the running time (at least on an iPhone12), but it doesn't solve this issue.

@benjamin-kramer
Copy link
Author

benjamin-kramer commented Jan 22, 2024

Note 2 -
There is a piece of code here that looks like it should allow points to be ignored, but it doesn't work (setting a label of -1 interferes with the detection of points with 0 / 1 labels).

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