code to add all of the appropriate ranks to a dict