def create_yaml_dict(camera_assignment, mjpeg_info_dict):
    """
    Creates camera assignment yaml dictionary for saving to file
    """
    # Create dictionary for yaml file
    yaml_dict = {}
    for camera_id, value in camera_assignment.iteritems():
        camera_name = 'camera_{0}'.format(value)
        computer = mjpeg_info_dict[camera_id]['computer']
        yaml_dict[camera_name] = {'guid': camera_id, 'computer': computer}
    return yaml_dict