tforce_btc_trader
tforce_btc_trader copied to clipboard
Typeerror occurred at tensorforce 0.4.3 When run hypersearch.py
I just run hypersearch.py
with no argument then get the following error.
I am not familiar with tensorforce but I know it happened statement in tensorforce/execution/runner.py
which show how episodes progress.
I could run hypersearch.py with my fixed tensorforce which is commentted out this error state btw.
My environment
- Tensorforce 0.4.3
- Tensorflow-gpu 1.13.1
- tforce_btc_trader v0.2
the error
Traceback (most recent call last):
File "hypersearch.py",
line 364, in <module>
main()
File "hypersearch.py", line 357, in main
best = fmin(loss_fn, space=space, algo=tpe.suggest, max_evals=max_evals, trials=trials)
File "/usr/local/lib/python3.6/site-packages/hyperopt/fmin.py", line 388, in fmin
show_progressbar=show_progressbar,
File "/usr/local/lib/python3.6/site-packages/hyperopt/base.py", line 639, in fmin
show_progressbar=show_progressbar)
File "/usr/local/lib/python3.6/site-packages/hyperopt/fmin.py", line 407, in fmin
rval.exhaust()
File "/usr/local/lib/python3.6/site-packages/hyperopt/fmin.py", line 262, in exhaust
self.run(self.max_evals - n_done, block_until_done=self.asynchronous)
File "/usr/local/lib/python3.6/site-packages/hyperopt/fmin.py", line 227, in run
self.serial_evaluate()
File "/usr/local/lib/python3.6/site-packages/hyperopt/fmin.py", line 141, in serial_evaluate
result = self.domain.evaluate(spec, ctrl)
File "/usr/local/lib/python3.6/site-packages/hyperopt/base.py", line 844, in evaluate
rval = self.fn(pyll_rval)
File "hypersearch.py", line 315, in loss_fn
env.train_and_test(agent)
File "/root/tforce_btc_trader/btc_env.py", line 255, in train_and_test
runner.run(timesteps=train_steps)
File "/root/tensorforce2/tensorforce/execution/runner.py", line 149, in run
pbar.update(num_episodes - self.global_episode)
TypeError: unsupported operand type(s) for -: 'NoneType' and 'int'