Instrumental response model and detrending for the Dark Energy Camera