Open binary files in the binary mode

Make sure that we are using binary mode to read binary files like images, this Fixes #20