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

Use local model file but have an error "Not allowed to load local resource: file:///D:/model/gemma-2b-it-gpu-int4.bin" #441

Open
akau16 opened this issue Aug 31, 2024 · 0 comments

Comments

@akau16
Copy link

akau16 commented Aug 31, 2024

When I run the llm_inference in localhost, it's ok to access model file like "gemma-2b-it-gpu-int4.bin" that is in project folder, but when I run llm_inference in Firebase Hosting, it can not access on-device's model file, it will show "Not allowed to load local resource: file:///D:/model/gemma-2b-it-gpu-int4.bin".
And I query it to get that info 'In standard HTML and JavaScript, it is not possible to directly specify to read files with a specific path on the local machine. This is due to browser security restrictions designed to protect user privacy and prevent malicious websites from automatically accessing the local file system'.

But I try your sample in MediaPipe Studio(https://mediapipe-studio.webapps.google.com/studio/demo/llm_inference), I can click 'Choose a model file' and select model file in my device and run OK, I would like to ask how can it do that? Thank you!

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