-
Notifications
You must be signed in to change notification settings - Fork 943
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
[Fix] Support fetching images when using worker engine #574
Conversation
The previous implementation relied on the HTMLImageElement constuctor which is not available in worker contexts.
Really appreciate the fix, will take a look soon! Meanwhile if convenient, could you provide a small example that wouldn't work with the previous implementation but will work now? Or would feeding image to |
Using the worker engine in examples/vision-model shows the issue: dstoc@d019388 Let me know if you want to add that change into this PR. |
I see!
That'd be great. Perhaps with a |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Tested on my end, works great; LGTM! Let's merge it after you add the web worker switch to vision-model.ts
. Thank you!
Added. |
Great work, thank you! |
Ahh I think the |
### Change - #574 - Enable image input for web/service worker ### TVMjs - No change, version `0.18.0-dev0` just like 0.2.66 - Built at apache/tvm@30fb16a
The previous implementation relied on the HTMLImageElement constuctor which is not available in worker contexts.
### Change - mlc-ai#574 - Enable image input for web/service worker ### TVMjs - No change, version `0.18.0-dev0` just like 0.2.66 - Built at apache/tvm@30fb16a
The previous implementation relied on the HTMLImageElement constuctor which is not available in worker contexts.