def create_hash(self, initial, capacity, error):
        self.hash = 0L
        self.hashbits, self.num_hashes = self._optimal_size(capacity, error)

        if len(initial):
            if type(initial) == str:
                self.add(initial)
            else:
                for t in initial:
                    self.add(t)
Calculates a Bloom filter with the specified parameters.
dataset/ETHPy150Open chineking/cola/cola/core/bloomfilter/__init__.py/BloomFilter.create_hash