Gab0 / japonicus

Genetic Algorithm for Gekko Trading Bot.
MIT License
284 stars 103 forks source link

Develop branch | Getting stuck on Locale2 #151

Open MeafQ opened 6 years ago

MeafQ commented 6 years ago

So I'm using the latest Gekko and Japonicus from develop branch on Windows. I don't understand is why requirements are different. Master branch require deap=1.2.0 while develop deap=1.0.2 that doesn't even exist for me (there is 1.0.2.post2 version tho). I tried both of them and it's always getting stuck (no CPU usage) on Locale2 except that deap=1.2.0 print me a bunch of warnings (each being repeated multiple times):

C:\Users\meafq\AppData\Local\Programs\Python\Python36-32\lib\site-packages\deap\tools\_hypervolume\pyhv.py:33: ImportWarning: Falling back to the python version of hypervolume module. Expect this to be very slow.

C:\Users\meafq\AppData\Local\Programs\Python\Python36-32\lib\importlib\_bootstrap.py:219: ImportWarning: can't resolve package from __spec__ or __package__, falling back on __name__ and __path__ return f(*args, **kwds)

C:\Users\meafq\AppData\Local\Programs\Python\Python36-32\lib\importlib\_bootstrap_external.py:426: ImportWarning: Not importing directory C:\Users\meafq\AppData\Local\Programs\Python\Python36-32\lib\site-packages\redbot\ext: missing __init__

C:\Users\meafq\AppData\Local\Programs\Python\Python36-32\lib\importlib\_bootstrap_external.py:426: ImportWarning: Not importing directory c:\users\meafq\appdata\local\programs\python\python36-32\lib\site-packages\mpl_toolkits: missing __init__

MeafQ commented 6 years ago

It seems Windows doesn't like deap=1.2.0, here is a discussion and also a solution to my warnings:

1.0.2.post2 or 1.2.2 versions work fine.

Gab0 commented 6 years ago

hey @MeafQ, so 1.2.2 solves the problem? Nice then, I will update requirements.txt. Did you see if it also gets rid of the multiple warnings at startup? cheers!

MeafQ commented 6 years ago

@Gab0 Warnings have disappeared but it still getting stuck without any errors on Locale2 with any version.

MeafQ commented 6 years ago
The profits reported here depends on backtest interpreter function;
        interpreter v3:
if <backtest profit> > 0: <shown profit> = <backtest profit> - <market profit>
else <shown profit> = <backtest profit>
C:/Gekko/japonicus/japonicus.py -gck --strat PPO
Evolving PPO strategy;

evaluated parameters ranges:
short                         (8.4, 15.6)

long                          (18.2, 33.8)

signal                        (6.3, 11.7)

thresholds.down               (-0.0325, -0.0175)

thresholds.up                 (0.0175, 0.0325)

thresholds.persistence        (1.4, 2.6)

evolution candlestick dataset 2018-06-30 23:21:00 to 2018-08-02 23:19:00
LTC/USDT @binance

evolution candlestick dataset 2018-06-30 23:21:00 to 2018-08-02 23:19:00
LTC/USDT @binance

evaluation candlestick dataset 2018-06-30 23:21:00 to 2018-08-02 23:19:00
LTC/USDT @binance

        ======  EPOCH 0/3000  ======
Locale1
first unevaluated: 50
0 individues removed due to equality
[50]
Population dead after profit filter.
Population dead after trading number filter.
Population dead after roundtrip exposure filter.
Repopulating... Aborting epoch.
EPOCH 0 &50
Maximum profit -25.781      Average profit -31.919
Minimum profit -40.124      Profit variation 3.629
Population size 50          Max population size 50
Avg trade number 216.280    Avg sharpe ratio -252.962
Avg exposure time 3.457

Locale2
first unevaluated: 50
0 individues removed due to equality
[50]
MeafQ commented 6 years ago

Okay, I runned japonicus without -k and it helped.