src/quagen/ai/biased.py
def _evaluate_candidates(self, candidate_spots):
        """
        Projects every candidate and chooses the spot with the highest
        projected score

        Args:
            candidate_spots (list): Spots to evaluate

        Returns:
            (tuple): Spot coordinates as (x, y)

        """
        best_candidate = None

        # Augment each selected spot with additional information which will
        # be used to reach a final spot score.
        augmented_candidates = [
            self._augment_candidate(spot) for spot in candidate_spots
        ]

        # Score all the augmented candidates using the augmented fields
        self._score_candidates(augmented_candidates)

        # Choose the highest scoring candidate
        augmented_candidates.sort(key=lambda spot: spot["score"], reverse=True)
        best_candidate = augmented_candidates[0]["coords"]

        for spot in augmented_candidates:
            logging.debug(f"Scored {spot}")

        return best_candidate

        Projects every candidate and chooses the spot with the highest
        projected score

        Args:
            candidate_spots (list): Spots to evaluate

        Returns:
            (tuple): Spot coordinates as (x, y)

        
Projects every candidate and chooses the spot with the highest
projected score
Projects every candidate and chooses the spot with the highest projected score
def _evaluate_candidates(self, candidate_spots):
        best_candidate = None
        augmented_candidates = [
            self._augment_candidate(spot) for spot in candidate_spots
        ]
        self._score_candidates(augmented_candidates)
        augmented_candidates.sort(key=lambda spot: spot["score"], reverse=True)
        best_candidate = augmented_candidates[0]["coords"]
        for spot in augmented_candidates:
            logging.debug(f"Scored {spot}")
        return best_candidate
def _evaluate_candidates ( self , candidate_spots ) : best_candidate = None augmented_candidates = [ self . _augment_candidate ( spot ) for spot in candidate_spots ] self . _score_candidates ( augmented_candidates ) augmented_candidates . sort ( key = lambda spot : spot [ "score" ] , reverse = True ) best_candidate = augmented_candidates [ 0 ] [ "coords" ] for spot in augmented_candidates : logging . debug ( f"Scored {spot}" ) return best_candidate
Projects every candidate and chooses the spot with the highest
projected score
Projects every candidate and chooses the spot with the highest projected score
"""
        Projects every candidate and chooses the spot with the highest
        projected score

        Args:
            candidate_spots (list): Spots to evaluate

        Returns:
            (tuple): Spot coordinates as (x, y)

        """ # Augment each selected spot with additional information which will # be used to reach a final spot score. # Score all the augmented candidates using the augmented fields # Choose the highest scoring candidate
Spot coordinates as (x, y)
Spot coordinates as ( x y )
(tuple)
self
candidate_spots
Spots to evaluate
Spots to evaluate