import pickle


def get_player_data(file_path):
    """Get the highscores data."""
    scores = {}

    try:
        with open(file_path, 'rb') as _file:
            scores = pickle.load(_file)
    except FileNotFoundError:
        print('File could not be found!')
        raise

    return scores