Input image translation to ubyte vector