How to optimize images in WordPress themes and plugins
Images that are outside of Media Library can be optimized if you go to Settings/ShortPixel in your /wp-admin and then select the Advanced tab.
There click on "Select.." button and select the folder where are the images that you'd like to optimize.
Once you did this make sure you run Bulk ShortPixel.
Bonus: Click here to see an example!