1
0
mirror of https://github.com/microsoft/qlib.git synced 2026-07-15 00:36:55 +08:00

Fix and update run_all_model

This commit is contained in:
Jactus
2020-12-01 11:54:26 +08:00
parent bb5f3cb33d
commit 77884db3a5
12 changed files with 42 additions and 26 deletions

View File

@@ -57,7 +57,7 @@ class GRU(Model):
loss="mse",
optimizer="adam",
GPU="0",
seed=0,
seed=None,
**kwargs
):
# Set logger.
@@ -113,8 +113,9 @@ class GRU(Model):
)
)
np.random.seed(self.seed)
torch.manual_seed(self.seed)
if self.seed is not None:
np.random.seed(self.seed)
torch.manual_seed(self.seed)
self.gru_model = GRUModel(
d_feat=self.d_feat,