https://www.coursehero.com/file/p2l5382l/between-0-and-1-the-function-automatically-converts-the-image-if-needed-to-be/