def filter(self, f):
        ids, vals = [], []
        for id in self.mIdentifiers:
            s = self.mMali[id]
            if f(s):
                vals.append(s)
                ids.append(id)
        self.mIdentifiers = ids
        self.mMali = vals
Internally strings are utf8 encoded.
dataset/ETHPy150Open CGATOxford/cgat/CGAT/Mali.py/Mali.filter--crossover with--dataset/ETHPy150Open google/grr/grr/lib/rdfvalues/structs.py/ProtoString.ConvertFromWireFormat