def specieset(structure):
    """ Returns ordered set of species.

        Especially usefull with VASP since we are sure what the list of species
        is always ordered the same way.
    """

    tmp = [a.type for a in structure]
    species = sorted(set(tmp), key=tmp.index)
    return species