have read_grid take a string rather than a filename