Commit 0a5739fa authored by Yuxin Wu's avatar Yuxin Wu

update docs

parent 50d95344
......@@ -35,7 +35,7 @@ For example, CPU/GPU utilization, output images, tensorboard curves, if relevant
### 4. Your environment:
+ Python version:
+ TF version: `python -c 'import tensorflow as tf; print(tf.GIT_VERSION, tf.VERSION)'`.
+ Tensorpack version: `python -c 'import tensorpack; print(tensorpack.__version__)'`.
+ Tensorpack version: `python -c 'import tensorpack; print(tensorpack.__version__);'`.
You can install Tensorpack master by `pip install -U git+https://github.com/ppwwyyxx/tensorpack.git`
and see if your issue is already solved.
+ If you're not using tensorpack under a normal command line shell (e.g.,
......
......@@ -67,7 +67,7 @@ Dependencies:
+ TensorFlow >= 1.3. (If you only want to use `tensorpack.dataflow` alone as a data processing library, TensorFlow is not needed)
```
pip install --upgrade git+https://github.com/tensorpack/tensorpack.git
# or add `--user` to avoid system-wide installation.
# or add `--user` to install to user's local directories
```
## Citing Tensorpack:
......
......@@ -12,7 +12,7 @@ with the support of:
+ [Group Normalization](https://arxiv.org/abs/1803.08494)
## Dependencies
+ Python 3; OpenCV.
+ Python 3.3+; OpenCV.
+ TensorFlow >= 1.6 (1.4 or 1.5 can run but may crash due to a TF bug);
+ pycocotools: `pip install 'git+https://github.com/cocodataset/cocoapi.git#subdirectory=PythonAPI'`
+ Pre-trained [ImageNet ResNet model](http://models.tensorpack.com/FasterRCNN/)
......
......@@ -2,7 +2,7 @@
# File: __init__.py
from tensorpack.libinfo import __version__, _HAS_TF
from tensorpack.libinfo import __version__, __git_version__, _HAS_TF
from tensorpack.utils import *
from tensorpack.dataflow import *
......
......@@ -687,7 +687,7 @@ class PrintData(ProxyDataFlow):
...
"""
def __init__(self, ds, num=1, label=None, name=None, max_depth=3, max_list=3):
def __init__(self, ds, num=1, name=None, max_depth=3, max_list=3):
"""
Args:
ds (DataFlow): input DataFlow.
......@@ -698,12 +698,7 @@ class PrintData(ProxyDataFlow):
"""
super(PrintData, self).__init__(ds)
self.num = num
if label:
log_deprecated("PrintData(label, ...", "Use PrintData(name, ... instead.", "2018-05-01")
self.name = label
else:
self.name = name
self.name = name
self.cnt = 0
self.max_depth = max_depth
self.max_list = max_list
......
......@@ -57,6 +57,7 @@ except ImportError:
_HAS_TF = False
# This line has to be the last line of the file.
# setup.py will use it to determine the version
# These lines will be programatically read/write by setup.py
# Don't touch them.
__version__ = '0.9.0.1'
__git_version__ = __version__
......@@ -147,7 +147,7 @@ def gpu_available_in_session():
return False
@deprecated("You should use get_tf_version_tuple instead due to the existence of TF 1.10")
@deprecated("Use get_tf_version_tuple instead.", "2019-01-31")
def get_tf_version_number():
return float('.'.join(tf.VERSION.split('.')[:2]))
......
......@@ -11,7 +11,7 @@ from ..callbacks import (
from ..dataflow.base import DataFlow
from ..graph_builder.model_desc import ModelDescBase
from ..utils import logger
from ..tfutils.sessinit import SessionInit, SaverRestore, JustCurrentSession
from ..tfutils.sessinit import SessionInit, SaverRestore
from ..tfutils.sesscreate import NewSessionCreator
from ..input_source import InputSource
......@@ -154,25 +154,6 @@ class TrainConfig(object):
self.tower = [0]
assert len(kwargs) == 0, "Unknown arguments: {}".format(kwargs.keys())
@property
def nr_tower(self):
logger.warn("TrainConfig.nr_tower was deprecated! Set the number of GPUs on the trainer instead!")
logger.warn("See https://github.com/tensorpack/tensorpack/issues/458 for more information.")
return len(self.tower)
@nr_tower.setter
def nr_tower(self, value):
logger.warn("TrainConfig.nr_tower was deprecated! Set the number of GPUs on the trainer instead!")
logger.warn("See https://github.com/tensorpack/tensorpack/issues/458 for more information.")
self.tower = list(range(value))
def _deprecated_parsing(self):
self.callbacks = self.callbacks or []
self.extra_callbacks = DEFAULT_CALLBACKS() if self.extra_callbacks is None else self.extra_callbacks
self.callbacks.extend(self.extra_callbacks)
self.monitors = DEFAULT_MONITORS() if self.monitors is None else self.monitors
self.session_init = self.session_init or JustCurrentSession()
class AutoResumeTrainConfig(TrainConfig):
"""
......
......@@ -11,7 +11,7 @@ from ..tfutils.sesscreate import NewSessionCreator
from ..utils import logger
from ..utils.argtools import map_arg
from ..utils.develop import HIDE_DOC
from ..utils.develop import HIDE_DOC, log_deprecated
from ..tfutils import get_global_step_var
from ..tfutils.distributed import get_distributed_session_creator
from ..tfutils.tower import TrainTowerContext
......@@ -171,7 +171,7 @@ class SyncMultiGPUTrainerReplicated(SingleCostTrainer):
if use_nccl is not None:
mode = 'nccl' if use_nccl else None
logger.warn("use_nccl option was deprecated! Use the `mode` option instead!")
log_deprecated("use_nccl option", "Use the `mode` option instead!", "2019-01-31")
if mode is None:
mode = 'hierarchical' if len(gpus) >= 8 else 'nccl'
mode = mode.lower()
......
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