def GetDimensions(nc):
    """Returns a dictionary describing the dimensions in a netCDF file."""
    return({name: {
        "size": dim.size, "UNLIMITED": True} if dim.isunlimited() else {
        "size": dim.size, "UNLIMITED": False}
    for name, dim in nc.dimensions.items()})