Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

word2vec_optimized text8 missing #14

Open
tobigithub opened this issue Nov 27, 2015 · 1 comment
Open

word2vec_optimized text8 missing #14

tobigithub opened this issue Nov 27, 2015 · 1 comment

Comments

@tobigithub
Copy link
Owner

TF gobble for missing a file or directory

root@fb729273837c:/tensorflow# bazel-bin/tensorflow/models/embedding/word2vec_optimized   --train_data=text8   --eval_data=questions-words.txt   --save_path=/tmp/
I tensorflow/core/common_runtime/local_device.cc:25] Local device intra op parallelism threads: 8
I tensorflow/core/common_runtime/local_session.cc:45] Local session inter op parallelism threads: 8
W tensorflow/models/embedding/word2vec_kernels.cc:23] Not found: text8
E tensorflow/core/framework/op_segment.cc:37] Create kernel failed: Not found: text8
E tensorflow/core/common_runtime/executor.cc:247] Executor failed to create kernel. Not found: text8
     [[Node: Skipgram = Skipgram[batch_size=500, filename="text8", min_count=5, subsample=0.001, window_size=5, _device="/job:localhost/replica:0/task:0/cpu:0"]()]]
Traceback (most recent call last):
  File "/tensorflow/bazel-bin/tensorflow/models/embedding/word2vec_optimized.runfiles/tensorflow/models/embedding/word2vec_optimized.py", line 410, in <module>
    tf.app.run()
  File "/tensorflow/bazel-bin/tensorflow/models/embedding/word2vec_optimized.runfiles/tensorflow/python/platform/default/_app.py", line 11, in run
    sys.exit(main(sys.argv))
  File "/tensorflow/bazel-bin/tensorflow/models/embedding/word2vec_optimized.runfiles/tensorflow/models/embedding/word2vec_optimized.py", line 395, in main
    model = Word2Vec(opts, session)
  File "/tensorflow/bazel-bin/tensorflow/models/embedding/word2vec_optimized.runfiles/tensorflow/models/embedding/word2vec_optimized.py", line 126, in __init__
    self.build_graph()
  File "/tensorflow/bazel-bin/tensorflow/models/embedding/word2vec_optimized.runfiles/tensorflow/models/embedding/word2vec_optimized.py", line 168, in build_graph
    opts.words_per_epoch) = self._session.run([words, counts, words_per_epoch])
  File "/tensorflow/bazel-bin/tensorflow/models/embedding/word2vec_optimized.runfiles/tensorflow/python/client/session.py", line 345, in run
    results = self._do_run(target_list, unique_fetch_targets, feed_dict_string)
  File "/tensorflow/bazel-bin/tensorflow/models/embedding/word2vec_optimized.runfiles/tensorflow/python/client/session.py", line 419, in _do_run
    e.code)
tensorflow.python.framework.errors.NotFoundError: text8
     [[Node: Skipgram = Skipgram[batch_size=500, filename="text8", min_count=5, subsample=0.001, window_size=5, _device="/job:localhost/replica:0/task:0/cpu:0"]()]]
Caused by op u'Skipgram', defined at:
  File "/tensorflow/bazel-bin/tensorflow/models/embedding/word2vec_optimized.runfiles/tensorflow/models/embedding/word2vec_optimized.py", line 410, in <module>
    tf.app.run()
  File "/tensorflow/bazel-bin/tensorflow/models/embedding/word2vec_optimized.runfiles/tensorflow/python/platform/default/_app.py", line 11, in run
    sys.exit(main(sys.argv))
  File "/tensorflow/bazel-bin/tensorflow/models/embedding/word2vec_optimized.runfiles/tensorflow/models/embedding/word2vec_optimized.py", line 395, in main
    model = Word2Vec(opts, session)
  File "/tensorflow/bazel-bin/tensorflow/models/embedding/word2vec_optimized.runfiles/tensorflow/models/embedding/word2vec_optimized.py", line 126, in __init__
    self.build_graph()
  File "/tensorflow/bazel-bin/tensorflow/models/embedding/word2vec_optimized.runfiles/tensorflow/models/embedding/word2vec_optimized.py", line 166, in build_graph
    subsample=opts.subsample)
  File "/tensorflow/bazel-bin/tensorflow/models/embedding/word2vec_optimized.runfiles/tensorflow/models/embedding/gen_word2vec.py", line 69, in skipgram
    name=name)
  File "/tensorflow/bazel-bin/tensorflow/models/embedding/word2vec_optimized.runfiles/tensorflow/python/ops/op_def_library.py", line 633, in apply_op
    op_def=op_def)
  File "/tensorflow/bazel-bin/tensorflow/models/embedding/word2vec_optimized.runfiles/tensorflow/python/framework/ops.py", line 1710, in create_op
    original_op=self._default_original_op, op_def=op_def)
  File "/tensorflow/bazel-bin/tensorflow/models/embedding/word2vec_optimized.runfiles/tensorflow/python/framework/ops.py", line 988, in __init__
    self._traceback = _extract_stack()

root@fb729273837c:/tensorflow# 

@tobigithub
Copy link
Owner Author

The tutorial and readme is probably based on a VM or docker image.
All computations and relative directories are based on c:/tensorflow# hence the main directory.
Not very clean. So best executed in the docker image from main

cd tensorflow
wget http://mattmahoney.net/dc/text8.zip -O text8.gz
gzip -d text8.gz -f
wget https://word2vec.googlecode.com/svn/trunk/questions-words.txt
bazel build -c opt tensorflow/models/embedding:all

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant