make sure size is a tuple