bug fix

in parallelization mode, using push_back to update a shared vector lead
to memory issue