cfrnet icon indicating copy to clipboard operation
cfrnet copied to clipboard

errors in the examples

Open AIAdventures opened this issue 8 years ago • 1 comments

Hi, I am running a linux mint machine in a virtual enviroment.

(python27) andrewcz@andrewcz-PORTEGE-Z30t-B ~/cfrnet $ cd ~ (python27) andrewcz@andrewcz-PORTEGE-Z30t-B ~ $ export TF_BINARY_URL=https://storage.googleapis.com/tensorflow/linux/cpu/tensorflow-0.10.0-cp27-none-linux_x86_64.whl (python27) andrewcz@andrewcz-PORTEGE-Z30t-B ~ $ pip install --ignore-installed --upgrade $TF_BINARY_URL Collecting tensorflow==0.10.0 from https://storage.googleapis.com/tensorflow/linux/cpu/tensorflow-0.10.0-cp27-none-linux_x86_64.whl Using cached https://storage.googleapis.com/tensorflow/linux/cpu/tensorflow-0.10.0-cp27-none-linux_x86_64.whl Collecting six>=1.10.0 (from tensorflow==0.10.0) Using cached six-1.10.0-py2.py3-none-any.whl Collecting numpy>=1.8.2 (from tensorflow==0.10.0) Using cached numpy-1.12.1-cp27-cp27mu-manylinux1_x86_64.whl Collecting mock>=2.0.0 (from tensorflow==0.10.0) Using cached mock-2.0.0-py2.py3-none-any.whl Collecting wheel (from tensorflow==0.10.0) Downloading wheel-0.29.0-py2.py3-none-any.whl (66kB) 100% |████████████████████████████████| 71kB 1.9MB/s Collecting protobuf==3.0.0b2 (from tensorflow==0.10.0) Using cached protobuf-3.0.0b2-py2.py3-none-any.whl Collecting funcsigs>=1; python_version < "3.3" (from mock>=2.0.0->tensorflow==0.10.0) Downloading funcsigs-1.0.2-py2.py3-none-any.whl Collecting pbr>=0.11 (from mock>=2.0.0->tensorflow==0.10.0) Using cached pbr-3.0.0-py2.py3-none-any.whl Collecting setuptools (from protobuf==3.0.0b2->tensorflow==0.10.0) Using cached setuptools-35.0.2-py2.py3-none-any.whl Collecting packaging>=16.8 (from setuptools->protobuf==3.0.0b2->tensorflow==0.10.0) Using cached packaging-16.8-py2.py3-none-any.whl Collecting appdirs>=1.4.0 (from setuptools->protobuf==3.0.0b2->tensorflow==0.10.0) Using cached appdirs-1.4.3-py2.py3-none-any.whl Collecting pyparsing (from packaging>=16.8->setuptools->protobuf==3.0.0b2->tensorflow==0.10.0) Using cached pyparsing-2.2.0-py2.py3-none-any.whl Installing collected packages: six, numpy, funcsigs, pbr, mock, wheel, pyparsing, packaging, appdirs, setuptools, protobuf, tensorflow Successfully installed appdirs-1.4.3 funcsigs-1.0.2 mock-2.0.0 numpy-1.12.1 packaging-16.8 pbr-3.0.0 protobuf-3.0.0b2 pyparsing-2.2.0 setuptools-35.0.2 six-1.10.0 tensorflow-0.10.0 wheel-0.29.0 (python27) andrewcz@andrewcz-PORTEGE-Z30t-B ~ $ git clone https://github.com/clinicalml/cfrnet.git fatal: destination path 'cfrnet' already exists and is not an empty directory. (python27) andrewcz@andrewcz-PORTEGE-Z30t-B ~ $ git clone https://github.com/clinicalml/cfrnet.git Cloning into 'cfrnet'... remote: Counting objects: 100, done. remote: Total 100 (delta 0), reused 0 (delta 0), pack-reused 100 Receiving objects: 100% (100/100), 3.34 MiB | 596.00 KiB/s, done. Resolving deltas: 100% (42/42), done. Checking connectivity... done. (python27) andrewcz@andrewcz-PORTEGE-Z30t-B ~ $ ./example_ihdp.sh bash: ./example_ihdp.sh: No such file or directory (python27) andrewcz@andrewcz-PORTEGE-Z30t-B ~ $ cd cfrnet/ (python27) andrewcz@andrewcz-PORTEGE-Z30t-B ~/cfrnet $ ./example_ihdp.sh

Run 1 of 20:

p_alpha: 0 Training with hyperparameters: alpha=0, lambda=0.0001 Training data: data/ihdp_npci_1-100.train.npz Test data: data/ihdp_npci_1-100.test.npz Loaded data with shape [672,25] Defining graph...

Traceback (most recent call last): File "cfr_net_train.py", line 428, in tf.app.run() File "/home/andrewcz/miniconda3/envs/python27/lib/python2.7/site-packages/tensorflow/python/platform/app.py", line 30, in run sys.exit(main(sys.argv)) File "cfr_net_train.py", line 421, in main run(outdir) File "cfr_net_train.py", line 277, in run CFR = cfr.cfr_net(x, t, y_, p, FLAGS, r_alpha, r_lambda, do_in, do_out, dims) File "/home/andrewcz/cfrnet/cfr/cfr_net.py", line 25, in init self.build_graph(x, t, y , p_t, FLAGS, r_alpha, r_lambda, do_in, do_out, dims) File "/home/andrewcz/cfrnet/cfr/cfr_net.py", line 129, in _build_graph h_rep_norm = h_rep / safe_sqrt(tf.reduce_sum(tf.square(h_rep), axis=1, keep_dims=True)) TypeError: reduce_sum() got an unexpected keyword argument 'axis' Configuration used, skipping Configuration used, skipping

Run 4 of 20:

p_alpha: 1 Training with hyperparameters: alpha=1, lambda=0.0001 Training data: data/ihdp_npci_1-100.train.npz Test data: data/ihdp_npci_1-100.test.npz Loaded data with shape [672,25] Defining graph...

Traceback (most recent call last): File "cfr_net_train.py", line 428, in tf.app.run() File "/home/andrewcz/miniconda3/envs/python27/lib/python2.7/site-packages/tensorflow/python/platform/app.py", line 30, in run sys.exit(main(sys.argv)) File "cfr_net_train.py", line 421, in main run(outdir) File "cfr_net_train.py", line 277, in run CFR = cfr.cfr_net(x, t, y_, p, FLAGS, r_alpha, r_lambda, do_in, do_out, dims) File "/home/andrewcz/cfrnet/cfr/cfr_net.py", line 25, in init self.build_graph(x, t, y , p_t, FLAGS, r_alpha, r_lambda, do_in, do_out, dims) File "/home/andrewcz/cfrnet/cfr/cfr_net.py", line 129, in _build_graph h_rep_norm = h_rep / safe_sqrt(tf.reduce_sum(tf.square(h_rep), axis=1, keep_dims=True)) TypeError: reduce_sum() got an unexpected keyword argument 'axis' Configuration used, skipping Configuration used, skipping Configuration used, skipping Configuration used, skipping Configuration used, skipping Configuration used, skipping Configuration used, skipping Configuration used, skipping Configuration used, skipping Configuration used, skipping Configuration used, skipping Configuration used, skipping Configuration used, skipping Configuration used, skipping Configuration used, skipping Configuration used, skipping

Evaluating experiment results/example_ihdp... Loading results from results/example_ihdp... Found 0 experiment configurations. Traceback (most recent call last): File "evaluate.py", line 97, in evaluate(config_file, overwrite, filters=filters) File "evaluate.py", line 59, in evaluate binary=binary) File "/home/andrewcz/cfrnet/cfr/evaluation.py", line 332, in evaluate raise Exception('No finished results found.') Exception: No finished results found. (python27) andrewcz@andrewcz-PORTEGE-Z30t-B ~/cfrnet $

Im not sure whats going on . all the errors come when i try and run the shell example. Many thanks, Andrew

AIAdventures avatar May 09 '17 11:05 AIAdventures

Hi,

Which version of TensorFlow are you using? It sounds like tf.reduce_sum does not have the "axis" argument.

The code has only been tested on TensorFlow 0.12.0-rc1.

Best, Fredrik

oddrose avatar May 09 '17 15:05 oddrose