def calculate_num_modules(slot_map):
    """
    Reads the slot map and counts the number of modules we have in total
    :param slot_map: The Slot map containing the number of modules.
    :return: The number of modules counted in the config.
    """
    return sum([len(v) for v in slot_map.values()])