Makes both picture and data modules more consistent API wise, and does a few extra validation checks for the input arguments.