Most likely these are fungus gnats. They live on debris that over time collects in your cooler and any duct work. Not sure what a "swamp cooler" is exactly. If it is a pad and fan system using a fiber mat for cooling, check all those areas for dirt and debris as well.