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

rangeError length out of range of buffer #96

Open
WD-CHINA opened this issue May 6, 2021 · 3 comments
Open

rangeError length out of range of buffer #96

WD-CHINA opened this issue May 6, 2021 · 3 comments

Comments

@WD-CHINA
Copy link

WD-CHINA commented May 6, 2021

const temp = tf.tensor(new Uint8Array(frame.data), [frame.height, frame.width, 4])
在这个方法中,ios14.5以上报rangeError length out of range of buffer错误,其他的没有问题

@WD-CHINA
Copy link
Author

WD-CHINA commented May 6, 2021

const video = tf.tidy(() => {
const temp = tf.tensor(new Uint8Array(frame.data), [frame.height, frame.width, 4])
const sliceOptions = getFrameSliceOptions(this.cameraPosition, frame.width, frame.height, this.displaySize.width, this.displaySize.height)
return temp.slice(sliceOptions.start, sliceOptions.size).resizeBilinear([this.displaySize.height, this.displaySize.width])
})

@WD-CHINA
Copy link
Author

WD-CHINA commented May 6, 2021

temp 无法输出直接报angeError length out of range of buffer,ios14.5以上

@cometwan
Copy link

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