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

Failed to create session: "RangeError: offset is out of bounds". Please check if the publicPath is set correctly. #123

Open
streetheroesru opened this issue May 28, 2024 · 1 comment

Comments

@streetheroesru
Copy link

Cannot pass image to removeBackground Function:

    axios
      .get('/images/user.jpeg', {
        responseType: 'arraybuffer',
      })
      .then(async (response) => {
        const buffer = Buffer.from(response.data, 'base64')

        const blob = await removeBackground(buffer, {
          device: 'cpu',
        })
        console.log(blob)
      })

Error:

index.mjs:5951 Uncaught (in promise) Error: Failed to create session: "RangeError: offset is out of bounds". Please check if the publicPath is set correctly.
    at eval (index.mjs:5951:13)
    at async createOnnxSession (index.mjs:5949:19)
    at async initBase (index.mjs:6143:19)
    at async initInference (index.mjs:6148:16)

What am i doing wrong?

@roshanaale9818
Copy link

I have the same issue.

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

2 participants