tommoral / adaptiveoptim Goto Github PK
View Code? Open in Web Editor NEWAdaptive optimization procedure
Adaptive optimization procedure
It's a great job!!! When I run the cmd, python NIPS_figures.py --data artificial --save_dir layer1, an error happened like below, I wonder how to solve.
Traceback (most recent call last):
File "/AdaptiveOptim/NIPS_figures.py", line 249, in
network = LinearNetwork(D, 1, gpu_usage=gpu_usage, exp_dir=NAME_EXP)
File "\AdaptiveOptim\adaopt\linear_network.py", line 28, in init
super().init(n_layers=n_layers, name=name, **kwargs)
File "\AdaptiveOptim\adaopt_loptim_network.py", line 22, in init
self._construct()
File "\AdaptiveOptim\adaopt_loptim_network.py", line 77, in _construct
self._train = self._mk_training_step()
File "\AdaptiveOptim\adaopt\linear_network.py", line 153, in _mk_training_step
_reg = tf.add_n(tf.get_collection("regularisation"))
File "C:\Anaconda3\envs\tensorflow-gpu\lib\site-packages\tensorflow\python\ops\math_ops.py", line 2222, in add_n
raise ValueError("inputs must be a list of at least one Tensor with the "
ValueError: inputs must be a list of at least one Tensor with the same dtype and shape
I use the cmd :
python NIPS_figures.py --data artificial --save_dir layer1
and I get the error:
Traceback (most recent call last):
File "NIPS_figures.py", line 305, in <module>
lr_init=lr_init/n_layers)
File "/Users/Sadjad/git/AdaptiveOptim/Lcod/facto_network.py", line 226, in train
self._feed_val = self._convert_feed(feed_val)
File "/Users/Sadjad/git/AdaptiveOptim/Lcod/_loptim_network.py", line 305, in _convert_feed
for k, v in feed.items():
AttributeError: 'int' object has no attribute ‘items'
The modifications I made to the code (I am running this on mac OS, so I don’t have GPU):
Since I have my tensorflow installed with python2.7.13, I had to replace:
I have numpy 1.12.0, matplotlib 1.5.3, and sklearn 0.17.1
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.