def get_thin_interval(self):
        """Gets the thin interval to use.

        If ``max_samples_per_chain`` is set, this will figure out what thin
        interval is needed to satisfy that criteria. In that case, the thin
        interval used must be a multiple of the currently used thin interval.
        """
        if self.max_samples_per_chain is not None:
            # the extra factor of 2 is to account for the fact that the thin
            # interval will need to be at least twice as large as a previously
            # used interval
            thinfactor = 2 * self.niterations // self.max_samples_per_chain
            # make the new interval is a multiple of the previous, to ensure
            # that any samples currently on disk can be thinned accordingly
            thin_interval = (thinfactor // self.thin_interval) * \
                self.thin_interval
            # make sure it's at least 1
            thin_interval = max(thin_interval, 1)
        else:
            thin_interval = self.thin_interval
        return thin_interval
def get_thin_interval ( self ) : if self . max_samples_per_chain is not None : thinfactor = 2 * self . niterations // self . max_samples_per_chain thin_interval = ( thinfactor // self . thin_interval ) * self . thin_interval thin_interval = max ( thin_interval , 1 ) else : thin_interval = self . thin_interval return thin_interval
Gets the thin interval to use.

        If ``max_samples_per_chain`` is set, this will figure out what thin
        interval is needed to satisfy that criteria. In that case, the thin
        interval used must be a multiple of the currently used thin interval.