One option is sfjpg2byte. It requires the JPEG library to be present at the compilation time.

< lena.jpg sfjpg2byte | sfdd type=float > lena.rsf

Another option (suggested by Vladimir Bashkardin) is to use the convert utility from ImageMagick.

< lena.jpg convert - lena.gray
echo in=lena.gray data_format=native_uchar n1=512 n2=512 | sfdd type=float > lena.rsf

or

< lena.jpg convert - lena.rgb
echo in=lena.rgb data_format=native_uchar n1=3 n2=512 n3=512 | sfdd type=float > lena.rsf