happynoom / DeepTrade_keras

http://www.deeplearning.xin
230 stars 122 forks source link

which you use keras version? #14

Closed myboyliu closed 6 years ago

myboyliu commented 6 years ago

python3.5 tensorflow=1.5 keras=2.1,there is error. MacBook-Pro:DeepTrade_keras boliu$ python gossip.py /Users/boliu/anaconda3/lib/python3.6/site-packages/h5py/init.py:34: FutureWarning: Conversion of the second argument of issubdtype from float to np.floating is deprecated. In future, it will be treated as np.float64 == np.dtype(float).type. from ._conv import register_converters as _register_converters Using TensorFlow backend. initializing..., learing rate 0.001, n_layers 1, n_hidden 16, dropout rate 0.3. WARNING:tensorflow:From /Users/boliu/anaconda3/lib/python3.6/site-packages/keras/backend/tensorflow_backend.py:1242: calling reduce_sum (from tensorflow.python.ops.math_ops) with keep_dims is deprecated and will be removed in a future version. Instructions for updating: keep_dims is deprecated, use keepdims instead 2018-07-25 17:04:10.161405: I tensorflow/core/platform/cpu_feature_guard.cc:137] Your CPU supports instructions that this TensorFlow binary was not compiled to use: SSE4.2 AVX AVX2 FMA Traceback (most recent call last): File "gossip.py", line 124, in make_model([30, 61], 3000, 512, lr=0.001) File "gossip.py", line 92, in make_model wp = WindPuller(input_shape=input_shape, lr=lr, n_layers=n_layers, n_hidden=n_hidden, rate_dropout=rate_dropout) File "/Volumes/BOOTCAMP/dlnlp/DeepTrade_keras/windpuller.py", line 46, in init metrics=['accuracy']) File "/Users/boliu/anaconda3/lib/python3.6/site-packages/keras/models.py", line 821, in compile **kwargs) File "/Users/boliu/anaconda3/lib/python3.6/site-packages/keras/engine/training.py", line 666, in compile loss_function = losses.get(loss) File "/Users/boliu/anaconda3/lib/python3.6/site-packages/keras/losses.py", line 113, in get return deserialize(identifier) File "/Users/boliu/anaconda3/lib/python3.6/site-packages/keras/losses.py", line 105, in deserialize printable_module_name='loss function') File "/Users/boliu/anaconda3/lib/python3.6/site-packages/keras/utils/generic_utils.py", line 159, in deserialize_keras_object ':' + function_name) ValueError: Unknown loss function:risk_estimation MacBook-Pro:DeepTrade_keras boliu$

happynoom commented 6 years ago

See readme doc, add functions to keras follow instructions