diff --git a/constants/__init__.py b/constants/__init__.py index 23d54c0..9da1130 100644 --- a/constants/__init__.py +++ b/constants/__init__.py @@ -30,7 +30,7 @@ # Project Constants. # --------------------------------- -__version__ = "2.5.0" +__version__ = "2.5.1" version_split = __version__.split(".") __spec_version__ = ( (1000 * int(version_split[0])) diff --git a/finetune/eval/if_eval/rule_factory.py b/finetune/eval/if_eval/rule_factory.py index 794c0be..5c7cccf 100644 --- a/finetune/eval/if_eval/rule_factory.py +++ b/finetune/eval/if_eval/rule_factory.py @@ -80,13 +80,13 @@ def generate_rule( """Generates a rule based on the provided rule_id and existing rules.""" match rule_id: case RuleId.WORD_COUNT_AT_MOST: - return WordCountAtMostRule(random.choice([x for x in range(50, 150, 5)])) + return WordCountAtMostRule(random.choice([x for x in range(25, 50, 5)])) case RuleId.WORD_COUNT_AT_LEAST: - return WordCountAtLeastRule(random.choice([x for x in range(25, 250, 10)])) + return WordCountAtLeastRule(random.choice([x for x in range(25, 50, 5)])) case RuleId.SENTENCE_COUNT_AT_MOST: - return SentenceCountAtMostRule(random.choice([x for x in range(1, 5)])) + return SentenceCountAtMostRule(random.choice([x for x in range(1, 4)])) case RuleId.SENTENCE_COUNT_AT_LEAST: - return SentenceCountAtLeastRule(random.choice([x for x in range(2, 5)])) + return SentenceCountAtLeastRule(random.choice([x for x in range(2, 4)])) case RuleId.ALL_UPPER_CASE: return UppercaseRule() case RuleId.ALL_LOWER_CASE: diff --git a/neurons/validator.py b/neurons/validator.py index ca37a78..bba3884 100644 --- a/neurons/validator.py +++ b/neurons/validator.py @@ -710,7 +710,8 @@ async def _try_set_weights(): with self.metagraph_lock: uids = self.metagraph.uids try: - success, message = self.subtensor.set_weights( + weight_subtensor = bt.subtensor(config=self.config) + success, message = weight_subtensor.set_weights( netuid=self.config.netuid, wallet=self.wallet, uids=uids, @@ -1502,6 +1503,6 @@ async def run(self): width = os.get_terminal_size().columns except: width = 0 - os.environ['COLUMNS'] = str(max(200,width)) + os.environ["COLUMNS"] = str(max(200, width)) asyncio.run(Validator().run())