diff --git a/pdf_agents/agents.py b/pdf_agents/agents.py index 62e55d4..1ecc9b2 100644 --- a/pdf_agents/agents.py +++ b/pdf_agents/agents.py @@ -273,11 +273,7 @@ def get_offline_objects() -> dict: ) def trigger_condition(self, uid) -> bool: - try: - det_pos = self.exp_catalog[uid].start["more_info"]["Det_1_Z"]["Det_1_Z"]["value"] - except KeyError: - det_pos = self.exp_catalog[uid].start["Det_1_Z"]["Det_1_Z"]["value"] - return det_pos > 4_000.0 + return True class PDFSequentialAgent(PDFBaseAgent, SequentialAgentBase): diff --git a/pdf_agents/sklearn.py b/pdf_agents/sklearn.py index ab3b1c1..e8cd0f5 100644 --- a/pdf_agents/sklearn.py +++ b/pdf_agents/sklearn.py @@ -205,6 +205,7 @@ def _sample_uncertainty_proxy(self, batch_size=1): return grid[top_indicies], centers def ask(self, batch_size=1): + """Get's a relative position from the agent. Returns a document and hashes the suggestion for redundancy""" suggestions, centers = self._sample_uncertainty_proxy(batch_size) kept_suggestions = [] if not isinstance(suggestions, Iterable):