SCUBA2: read header from input file if given

Rather than assuming that the given file is associated with the
current Frame object, this primitive now reads the header directly
from the file to ensure the correct MAP_WDTH and MAP_HGHT are
used. However, if the width and height have been given as input
parameters, the header can be simply obtained from the current Frame
as the width and height entries will be updated.