foreach($model->images as $image){
$imagine = (new Imagine())->open(Yii::$app->basePath . '/../all_assets/uploads/' . $img->name);
$imagine->resize($imagine->getSize()->widen(200))->save(Yii::$app->basePath . '/../all_assets/uploads/thumb_' . $img->name);
}# end of "foreach($model->images as $image)"
$obj = new Imagine();
foreach($model->images as $image){
$imagine = $obj->open(Yii::$app->basePath . '/../all_assets/uploads/' . $img->name);
$imagine->resize($imagine->getSize()->widen(200))->save(Yii::$app->basePath . '/../all_assets/uploads/thumb_' . $img->name);
}# end of "foreach($model->images as $image)"
I bet the second option because of you create Imagine object only once (less memory is used). You have to investigate it by adding profiler, then you will know for sure.