removeFirst causes a data copy which can very quickly grow memory since this method may be called hundreds of thousands of times. I can escalate my machine to many GB of memory in a couple seconds when unpacking large arrays.
The fix uses a subdata call to avoid the copy issue.
removeFirst
causes a data copy which can very quickly grow memory since this method may be called hundreds of thousands of times. I can escalate my machine to many GB of memory in a couple seconds when unpacking large arrays.The fix uses a subdata call to avoid the copy issue.