From a0af21d4b944f4ffe61672343763b1fc8a0edc70 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Petr=C3=B4nio=20C=C3=A2ndido?= Date: Fri, 18 Jan 2019 09:18:46 -0200 Subject: [PATCH] Lag initialization on Hyperparam.Evolutive --- pyFTS/hyperparam/Evolutionary.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/pyFTS/hyperparam/Evolutionary.py b/pyFTS/hyperparam/Evolutionary.py index f09a622..e9a806d 100644 --- a/pyFTS/hyperparam/Evolutionary.py +++ b/pyFTS/hyperparam/Evolutionary.py @@ -42,13 +42,14 @@ def random_genotype(): :return: the genotype, a dictionary with all hyperparameters ''' order = random.randint(1, 3) + lags = [k for k in np.arange(1, order+1)] return genotype( random.randint(1, 4), random.randint(10, 100), random.randint(1, 2), order, random.uniform(0, .5), - sorted(random.sample(range(1, 50), order)), + lags, None, None )