What does correcting IQ do?
Here are some graphics I have to add to the other good answers, as well as typical correction schemes for DC Offset and IQ Imbalance.
DC OFFSET
Below is an example DC Offset on a 16 QAM signal (with some added AWGN). In this example the offset if shifted by an amount such that the power in the fixed vector representing the shift is 10 dB below the total power in the signal. Notice that the shift can be at any magnitude and phase and the fact that it does not change with time makes it &quot;DC&quot;. Also notice that even though it is 10 dB BELOW the total power in the signal, it appears significantly higher in the spectrum plot which may confuse some observers: this is because the waveform's power is spread over the modulation bandwidth, so the power in each FFT bin is lower than the power in the DC offset.

Below is a simple approach for eliminating DC offset. This filter is also introduced in this post: Transfer function of second order notch filter, where the gain constant $\alpha$ controls the bandwidth, getting tighter as $\alpha$ approaches 1.

IQ IMBALANCE
IQ Imbalance is demonstrated on the same 16 QAM signal in the next figure below, showing how it can result from either amplitude imbalance or phase imbalance or both. With amplitude imbalance, the scale of one axis is changed from the other, with phase imbalance, the axis are no longer in perfect quadrature.

The correction for IQ Imbalance is done as in the figure below with an $\alpha$ gain factor shown for amplitude imbalance and a $\beta$ gain factor shown for quadrature imbalance.