Why is a plastic bag transparent in infrared light? This is a classic trick to do with a IR camera:

Bu why is the plastic bag transparent, while the glasses aren't? I've also heard that water is not transparent in IR light. What causes this phenomena?
 A: the physical reason why this is happening is that absorption of a medium is frequency dependent.
Mathematical description
The most prominent example of a natural description might be the Lambert-Beer law that states that the change of a quantity $q$, $dq/dx$ is related to its value at $x$ multiplied by a scalar factor $\lambda$, which might depend on some further parameters like the frequency $\nu$,
$$\frac{dq}{dx} = -\lambda(\nu) q$$
which has the solution
$$q(x) = q_0 e^{-\lambda(\nu) x}\, .$$
For our scenario, $x$ might be the distance a light ray already traveled into the plastic bag, $x\in[0,D_{bag}]$. In optics, one often uses the extinction coefficient $n''(\nu)$, the imaginary part of the index of refraction or the absorbance $A_\lambda$ giving the same information for $\Delta x=\lambda$ (to clearify: $\lambda$ here is the wavelength, not the parameter above).
Electromagnetic case - penetration depth
Let us look directly at electrodynamics and how the Lambert-Beer law can be applied here.
We know that the absolute of the wave vector in a medium described by the (frequency dependent) refractive index $n(\omega) = n'(\omega) + \mathrm{i}n''(\omega)$ is given by $$k = \sqrt{n'(\omega) + \mathrm{i}n''(\omega)}\frac{\omega}{c}\, .$$
If now $n'  \gg n'' $ (which is true far away for resonances), we can expand it as
$$k = \sqrt{n'}\left(1 + \frac{\mathrm{i}}{2} \frac{n''}{n'} +\mathcal{O}\left(\frac{n''}{n'}\right)^2 \right)\frac{\omega}{c}\, .$$
Then, for a field $$\mathbf{E} \sim \mathbf{E_0} e^{\mathrm{i}{\mathbf{k\cdot r}-\omega t}}$$
we find that $$\frac{|\mathbf{E}|}{|\mathbf{E_0}|} \leq \frac{1}{e}$$
after a penetration depth of
$$d_p \approx 2 \frac{\sqrt{n'}}{n''}\frac{c}{\omega}\, .$$
This quantity can be seen as a characteristic propagation length.
Light absorption of a plastic bag
Since plastic bags are often made of polyethylene, we have to search for the spectral properties of it in the visible and infrared range to be able to answer the question. A quick search revealed that in Optical Properties of Polyethylene: Measurement and Applications on page four $n''(\nu)$ is given depending on the frequency in terms of eV (visible light ranges roughly in 1.5 - 3 eV, IR is energetically lower).
With an $n''\leq 10^{-5}$ as may be interpreted from the figure given in the paper, we can calculate
$$d_p \approx 6\mathrm{cm}$$
if I did not miscalculate totally. So, we have to state that polyethylene cannot be accounted for the absorption alone as stated by gigacyan and Georg - other absorbing effects need to be considered (In the given case we can only speculate that it maybe was doping with carbon which causes the bag to appear black). These effects will result in a change of $n(\omega)$ including its imaginary part, hence resulting in a changed penetration depth.
But this discussion is beyond the scope of this answer - one would have to calculate the electronic band structure of the material which is not an easy task of solid-state physics.
Nevertheless, I hope my explanations are sufficient to explain makroskopic absorption phenomena including the one considered here.
Sincerely
Robert
A: I am not a specialist in thermal vision so I will just answer your last question: what causes these phenomena?
Electromagnetic radiation (e.g. visible light) propagates through matter by polarizing it. Oscillating electromagnetic field polarizes molecule that, in turn, begins to emit electromagnetic radiation, and this cycle continues until the light comes from the other side.
Except, often it doesn't. If the frequency of the field is close to a resonant frequency of the molecule, the photon can be absorbed and its energy will be converted to heat. These resonances can be of different nature: absorption in the visible range is caused by electrons whereas nuclear motion is resonant with lower frequencies in the IR range. These resonances are individual and can be used for identifying molecules by measuring light absorption versus wavelength (it's called Spectrophotometry).
Update: In case of conductors like metals or, in this case, black carbon, free electrons are resonant to any frequency and these materials can observe light of any wavelength. However, as Georg pointed out, particles of carbon black are much smaller than the wavelength of thermal IR (10 $\mu$m) and this could be the reason of small absorption efficiency.
