renpas22 commited on
Commit ·
f15c2d7
1
Parent(s): c74a578
Add type conversion for RLConfig parameters
Browse files
src/reasoning/step_level_cot.py
CHANGED
|
@@ -76,15 +76,15 @@ class StepLevelCoTTrainer:
|
|
| 76 |
max_steps=self.config.max_reasoning_steps,
|
| 77 |
)
|
| 78 |
|
| 79 |
-
# Initialize RL trainer
|
| 80 |
rl_config = RLConfig(
|
| 81 |
-
clip_epsilon=self.config.ppo_clip_epsilon,
|
| 82 |
-
value_loss_coef=self.config.value_loss_coef,
|
| 83 |
-
entropy_coef=self.config.entropy_coef,
|
| 84 |
-
gamma=self.config.gamma,
|
| 85 |
-
gae_lambda=self.config.gae_lambda,
|
| 86 |
-
learning_rate=self.config.rl_learning_rate,
|
| 87 |
-
batch_size=self.config.train_batch_size,
|
| 88 |
use_prm_rewards=True,
|
| 89 |
normalize_rewards=True,
|
| 90 |
)
|
|
|
|
| 76 |
max_steps=self.config.max_reasoning_steps,
|
| 77 |
)
|
| 78 |
|
| 79 |
+
# Initialize RL trainer with explicit type conversion
|
| 80 |
rl_config = RLConfig(
|
| 81 |
+
clip_epsilon=float(self.config.ppo_clip_epsilon),
|
| 82 |
+
value_loss_coef=float(self.config.value_loss_coef),
|
| 83 |
+
entropy_coef=float(self.config.entropy_coef),
|
| 84 |
+
gamma=float(self.config.gamma),
|
| 85 |
+
gae_lambda=float(self.config.gae_lambda),
|
| 86 |
+
learning_rate=float(self.config.rl_learning_rate),
|
| 87 |
+
batch_size=int(self.config.train_batch_size),
|
| 88 |
use_prm_rewards=True,
|
| 89 |
normalize_rewards=True,
|
| 90 |
)
|