It’s all about the pressure of the air in the bottle, Pair.
Clearly, Pair + h1ρg > Patm, if not water will not be squirting out of the bottom hole.
Also, Pair + h2ρg < Patm, if not air will not be “sucked” through the upper holes.
Putting the two inequalities together, we get
Patm – h1ρg < Pair < Patm – h2ρg.
Basically, as water drains from the bottom hole, Pair drops due to expansion of the air pocket, drawing air into the bottle through the upper holes. This top up of air molecules to the air space increases Pair, ensuring that water continues to drain from the bottom hole.
Some interesting observations
0:42 – The water squirts out at a much faster rate when the bottle is uncapped. This shows that Pair is less than atmospheric when the bottle is capped.
0:54 – The water squirts out in spurts, suggesting that Pair fluctuates between the maximum and minimum values.
2:00 – At the instant when the water level dropped below upper holes, Pair increases to Patm. This results in a sudden increase in the speed of the water stream. It also became a steady stream instead of spurts.
2:26 – The stream stops before the water level reaches the bottom hole because of surface tension of the water.
The full-length unedited version is also made available if you want to do some analysis yourself.