Preserve existing loop when altering main loop

I came across a scenario where I was using the 'product_category' shortcode on the Shop page content to display categories at the top of the shop page - like products from a featured category.

I noticed that setting the 'columns' attribute in the shortcode affected not only the shortcode's loop, but the main loop further down the page.

I'm not sure that using such a method as I've created here is best, but I wanted to bring this up so that it can be addressed. I'd assume that issues such as this exist in other instances where the main $woocommerce_loop is altered.

As a note - I did attempt to use 'woocommerce_reset_loop()' at the end of the function before it returned. However, it did not have the desired effect.