def __init__(self, distribution, kernel, Z, threshold, spread):
        if not isinstance(distribution, Distribution):
            raise TypeError("Target must be a Distribution object")
        
        if not isinstance(kernel, Kernel):
            raise TypeError("Kernel must be a Kernel object")
        
        if not type(Z) is numpy.ndarray:
            raise TypeError("History must be a numpy array")
        
        if not len(Z.shape) == 2:
            raise ValueError("History must be a 2D numpy array")
        
        if not Z.shape[1] == distribution.dimension:
            raise ValueError("History dimension does not match target dimension")
        
        if not Z.shape[0] > 0:
            raise ValueError("History must contain at least one point")
        
        if not type(threshold) is float:
            raise TypeError("Threshold must be a float")
        
        if not type(spread) is float:
            raise TypeError("Spread must be a float")
        
        if not (spread > 0. and 1. < spread):
            raise ValueError("Spread must be a probability")
        
        MCMCSampler.__init__(self, distribution)
        
        self.kernel = kernel
        self.Z = Z
        self.threshold = threshold
        self.spread = spread
dataset/ETHPy150Open karlnapf/kameleon-mcmc/kameleon_mcmc/mcmc/samplers/DiscreteKameleon.py/DiscreteKameleon.__init__/swapped operands of `<`