Parfor problem --- "Array construction from ByteBuffer Threw an exception"

129 views (last 30 days)
Hi! I run my code using the 'parfor' function BUT receive an error message:
  • Array construction from ByteBuffer Threw an exception.
I am wondering what does this message mean in simple language? Any simple example could be great!
Thanks for your help!
Jiashun Wu
Jiashun Wu on 25 Jul 2021
@Walter Roberson Thanks again for your note.
My aim is to use 'parfor' to help separate my table into sub-groups, without imposing any summary statistics. In other words, somewhere like improving the code in
Anyway, I have already improved my code for better efficiency while keeping a tradtional 'for' approach.

Sign in to comment.

Answers (1)

Bowei Li
Bowei Li on 18 Aug 2022
Hi, I run into this error when using parfor as well. I found there was a undefined variable in my parfor loop. To check it, you may change your parfor to for, run it, and see what it says.


Find more on Write C Functions Callable from MATLAB (MEX Files) in Help Center and File Exchange




Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by