def _is_from_chemical_system(chemical_system, struct):
        """
        checks if the structure object is from the given chemical system
        """
        chemsys = list(set([sp.symbol for sp in struct.composition]))
        if len(chemsys) != len(chemical_system):
            return False
        for el in chemsys:
            if not el in chemical_system:
                return False
        return True