def get_indices(self, src, ridx, mag):
        """
        :param src: an UCERF source
        :param ridx: a set of rupture indices
        :param mag: magnitude to use to compute the integration distance
        :returns: array with the IDs of the sites close to the ruptures
        """
        centroids = src.get_centroids(ridx)
        mindistance = min_geodetic_distance(
            (centroids[:, 0], centroids[:, 1]), self.sitecol.xyz)
        idist = self.integration_distance(DEFAULT_TRT, mag)
        indices, = (mindistance <= idist).nonzero()
        return indices
def get_indices ( self , src , ridx , mag ) : centroids = src . get_centroids ( ridx ) mindistance = min_geodetic_distance ( ( centroids [ : , 0 ] , centroids [ : , 1 ] ) , self . sitecol . xyz ) idist = self . integration_distance ( DEFAULT_TRT , mag ) indices , = ( mindistance <= idist ) . nonzero ( ) return indices
:param src: an UCERF source
        :param ridx: a set of rupture indices
        :param mag: magnitude to use to compute the integration distance
        :returns: array with the IDs of the sites close to the ruptures