Re-implementation of VGG Network in tensorflow
pip install pyyaml skimage skdata tensorflow-gpu
python train_model_simple.py experiment.yaml
python train_model_parallel.py experiment.yaml
python predict.py dog.jpg
Re-implementation of VGG Network in tensorflow
License: MIT License
in vgg.py, line 21,
net = tf.sub(input_tensor, mu, name="input_mean_centered")
latest version of tensorflow (1.3) should be
net = tf.subtract(input_tensor, mu, name="input_mean_centered")
1. tf.pack
---> tf.stack
2. tf.softmax_cross_entropy_with_logits(logits, onehot_labels, name='xentropy')
---> tf.softmax_cross_entropy_with_logits(logits=logits, labels=onehot_labels, name='xentropy')
3. add conv3_3 : net = L.conv(net, name="conv3_3", kh=3, kw=3, n_out=256)
The function MetricsLogger is missing from tools.py
you're applying a relu to your logits
https://github.com/huyng/tensorflow-vgg/blob/master/vgg.py#L59
In vgg.py, block 3 only contains 2 conv layers and 1 pool layer. However, from the paper, it shows there should be 3 conv layers and 1 pool layer in block 3.
When I ran the code as it is, the accuracy (loss) wasn't that great. Anyone seeing such issues. I changed the batch size to 50. Apart from that no other change.
I hope you describe the environment that you checked.
I guess some of the functions that you used are not supported by the current version anymore.
The result is error when predict using model trainning from cifar-10.
(windows7+Python 3.6.4+TensorFlow 1.7)
When I run python train_model_simple.py experiment.yaml , an error occur.
Error:
'function' object has no attribute 'config_file'
they are happens in
parser = argparse.ArgumentParser()
parser.add_argument('config_file', help='YAML formatted config file')
args = parser.parse_args()
with open(args.config_file) as fp:
config.update(yaml.load(fp))
How should I do,help me. Thanks
(windows7+Python 3.6.4+TensorFlow 1.7)
When I run python train_model_simple.py experiment.yaml , an error occur.
Error:
from skdata.cifar10.dataset import CIFAR10
ModuleNotFoundError: No module named 'skdata'
How should I do,help me. Thanks
Line 77 in train_model_simple.py:
log = tools.MetricsLogger(train_log_fpath)
Also line 57 in train_model_parallel.py:
log = tools.MetricsLogger(train_log_fpath)
As the title indicated.
the last few lines of train_model_simple.py has problems:
args = parser.parse_args()
with open(args.config_file) as fp:
config.update(yaml.load(fp))
My environment : windows7+Anaconda3(python 3.6.4+Tensorflow 1.7)
Please help me,Thanks !
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.