added code to open image and apply filter