tensor2tensor icon indicating copy to clipboard operation
tensor2tensor copied to clipboard

DeprecationWarning and import warning:

Open Satan012 opened this issue 7 years ago • 2 comments

Description

when i use command from tensor2tensor import problems, there are two kinds of warning will be showed in the console. 1、eprecationWarning: inspect.getargspec() is deprecated, use inspect.signature() or inspect.getfullargspec() return _inspect.getargspec(target)

2、ImportWarning: can't resolve package from spec or package, falling back on name and path return f(*args, **kwds)

and when i use problem.generate_data(data_dir, tmp_dir) to generate tfrecord files for cnn_dailymail problem, it failed.

Environment information

OS: <your answer here>

$ pip freeze | grep tensor
# your output here

$ python -V
python3.6.6

For bugs: reproduction and error logs

# Steps to reproduce:
...

`from tensor2tensor import problems

data_dir = 'F:\sunmingsheng\Datasets\tensor2tensnor\cnn_daily\data' tmp_dir = 'F:\sunmingsheng\Datasets\tensor2tensnor\cnn_daily\tmp' problem = problems.problem('summarize_cnn_dailymail32k') problem.generate_data(data_dir, tmp_dir)`

# Error logs:
...E:\Anaconda2\envs\python3\python.exe F:/sunmingsheng/satan1/test1.py
E:\Anaconda2\envs\python3\lib\site-packages\tensorflow\python\util\tf_inspect.py:75: DeprecationWarning: inspect.getargspec() is deprecated, use inspect.signature() or inspect.getfullargspec()
  return _inspect.getargspec(target)
E:\Anaconda2\envs\python3\lib\site-packages\tensorflow\python\util\tf_inspect.py:75: DeprecationWarning: inspect.getargspec() is deprecated, use inspect.signature() or inspect.getfullargspec()
  return _inspect.getargspec(target)
E:\Anaconda2\envs\python3\lib\site-packages\tensorflow\python\util\tf_inspect.py:75: DeprecationWarning: inspect.getargspec() is deprecated, use inspect.signature() or inspect.getfullargspec()
  return _inspect.getargspec(target)
E:\Anaconda2\envs\python3\lib\site-packages\tensorflow\python\util\tf_inspect.py:75: DeprecationWarning: inspect.getargspec() is deprecated, use inspect.signature() or inspect.getfullargspec()
  return _inspect.getargspec(target)
E:\Anaconda2\envs\python3\lib\site-packages\tensorflow\python\util\tf_inspect.py:75: DeprecationWarning: inspect.getargspec() is deprecated, use inspect.signature() or inspect.getfullargspec()
  return _inspect.getargspec(target)
E:\Anaconda2\envs\python3\lib\site-packages\tensorflow\python\util\tf_inspect.py:75: DeprecationWarning: inspect.getargspec() is deprecated, use inspect.signature() or inspect.getfullargspec()
  return _inspect.getargspec(target)
E:\Anaconda2\envs\python3\lib\site-packages\tensorflow\python\util\tf_inspect.py:75: DeprecationWarning: inspect.getargspec() is deprecated, use inspect.signature() or inspect.getfullargspec()
  return _inspect.getargspec(target)
E:\Anaconda2\envs\python3\lib\site-packages\tensorflow\python\util\tf_inspect.py:75: DeprecationWarning: inspect.getargspec() is deprecated, use inspect.signature() or inspect.getfullargspec()
  return _inspect.getargspec(target)
E:\Anaconda2\envs\python3\lib\importlib\_bootstrap.py:219: ImportWarning: can't resolve package from __spec__ or __package__, falling back on __name__ and __path__
  return f(*args, **kwds)
E:\Anaconda2\envs\python3\lib\site-packages\tensor2tensor\utils\registry.py:180: DeprecationWarning: inspect.getargspec() is deprecated, use inspect.signature() or inspect.getfullargspec()
  args, varargs, keywords, _ = inspect.getargspec(rhp_fn)
E:\Anaconda2\envs\python3\lib\site-packages\tensor2tensor\utils\registry.py:180: DeprecationWarning: inspect.getargspec() is deprecated, use inspect.signature() or inspect.getfullargspec()
  args, varargs, keywords, _ = inspect.getargspec(rhp_fn)

Satan012 avatar Dec 12 '18 05:12 Satan012

I have the same problem.

aeloyq avatar Dec 18 '18 14:12 aeloyq

你知道怎么用t2t-trainer吗,这是一条命令吗

| | 孙铭声 邮箱:[email protected] |

签名由 网易邮箱大师 定制

On 12/18/2018 22:02, Chan Yu wrote:

I have the same problem.

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or mute the thread.

Satan012 avatar Dec 19 '18 01:12 Satan012