optimize progress in queryset