Commit 9c42c84f authored by Yuxin Wu's avatar Yuxin Wu

sort varnames in logging

parent 4e7977f5
...@@ -5,7 +5,7 @@ See some [examples](examples) to learn about the framework: ...@@ -5,7 +5,7 @@ See some [examples](examples) to learn about the framework:
### Vision: ### Vision:
+ [DoReFa-Net: train binary / low-bitwidth CNN on ImageNet](examples/DoReFa-Net) + [DoReFa-Net: train binary / low-bitwidth CNN on ImageNet](examples/DoReFa-Net)
+ [Train ResNet on ImageNet/Cifar10/SVHN](examples/ResNet) + [Train ResNet on ImageNet / Cifar10 / SVHN](examples/ResNet)
+ [InceptionV3 on ImageNet](examples/Inception/inceptionv3.py) + [InceptionV3 on ImageNet](examples/Inception/inceptionv3.py)
+ [Fully-convolutional Network for Holistically-Nested Edge Detection(HED)](examples/HED) + [Fully-convolutional Network for Holistically-Nested Edge Detection(HED)](examples/HED)
+ [Spatial Transformer Networks on MNIST addition](examples/SpatialTransformer) + [Spatial Transformer Networks on MNIST addition](examples/SpatialTransformer)
...@@ -58,10 +58,12 @@ The components are designed to be independent. You can use Model or DataFlow in ...@@ -58,10 +58,12 @@ The components are designed to be independent. You can use Model or DataFlow in
+ other requirements: + other requirements:
``` ```
pip install --user -r requirements.txt pip install --user -r requirements.txt
pip install --user -r opt-requirements.txt (some optional dependencies, you can install later if needed) pip install --user -r opt-requirements.txt # (some optional dependencies, you can install later if needed)
``` ```
+ Enable `import tensorpack` (or use `greadlink` from `coreutils` brew package if you're on OSX): + Enable `import tensorpack`:
``` ```
export PYTHONPATH=$PYTHONPATH:`readlink -f path/to/tensorpack` export PYTHONPATH=$PYTHONPATH:`readlink -f path/to/tensorpack`
``` ```
(or use `greadlink` from `coreutils` brew package if you're on OSX)
+ Use tcmalloc if running with large data + Use tcmalloc if running with large data
...@@ -141,7 +141,7 @@ class SaverRestore(SessionInit): ...@@ -141,7 +141,7 @@ class SaverRestore(SessionInit):
logger.warn("Variable {} in the graph not found in checkpoint!".format(v.op.name)) logger.warn("Variable {} in the graph not found in checkpoint!".format(v.op.name))
if len(chkpt_vars_used) < len(vars_available): if len(chkpt_vars_used) < len(vars_available):
unused = vars_available - chkpt_vars_used unused = vars_available - chkpt_vars_used
for name in unused: for name in sorted(unused):
if not is_training_name(name): if not is_training_name(name):
logger.warn("Variable {} in checkpoint not found in the graph!".format(name)) logger.warn("Variable {} in checkpoint not found in the graph!".format(name))
return var_dict return var_dict
...@@ -167,10 +167,10 @@ class ParamRestore(SessionInit): ...@@ -167,10 +167,10 @@ class ParamRestore(SessionInit):
logger.info("Params to restore: {}".format( logger.info("Params to restore: {}".format(
', '.join(map(str, intersect)))) ', '.join(map(str, intersect))))
for k in variable_names - param_names: for k in sorted(variable_names - param_names):
if not is_training_name(k): if not is_training_name(k):
logger.warn("Variable {} in the graph not found in the dict!".format(k)) logger.warn("Variable {} in the graph not found in the dict!".format(k))
for k in param_names - variable_names: for k in sorted(param_names - variable_names):
logger.warn("Variable {} in the dict not found in the graph!".format(k)) logger.warn("Variable {} in the dict not found in the graph!".format(k))
upd = SessionUpdate(sess, upd = SessionUpdate(sess,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment