introduction of the new function read_field to read both netcdf files and images with a unified method, used in refresh_field in uvmat