Predicting the Yields of Photometric Surveys for Transiting Planets