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

Unable to run TensorBoard after TF v1.4 upgrade #764

Closed
Carmezim opened this issue Nov 21, 2017 · 5 comments
Closed

Unable to run TensorBoard after TF v1.4 upgrade #764

Carmezim opened this issue Nov 21, 2017 · 5 comments
Assignees

Comments

@Carmezim
Copy link

Carmezim commented Nov 21, 2017

Python 3.6
OS High Sierra
TensorFlow v1.4

As reported here and in this SO question Tensorboard gives the following error when it's ran:

Traceback (most recent call last):
  File "/usr/local/bin/tensorboard", line 11, in <module>
    sys.exit(main())
  File "/usr/local/lib/python3.6/site-packages/tensorboard/main.py", line 39, in main
    return program.main(default.get_plugins(),
  File "/usr/local/lib/python3.6/site-packages/tensorboard/default.py", line 71, in get_plugins
    debugger = debugger_plugin_loader.get_debugger_plugin()
  File "/usr/local/lib/python3.6/site-packages/tensorboard/plugins/debugger/debugger_plugin_loader.py", line 46, in get_debugger_plugin
    if FLAGS.debugger_data_server_grpc_port is None:
  File "/usr/local/lib/python3.6/site-packages/absl/flags/_flagvalues.py", line 509, in __getattr__
    raise _exceptions.UnparsedFlagAccessError(error_message)
absl.flags._exceptions.UnparsedFlagAccessError: Trying to access flag --debugger_data_server_grpc_port before flags were parsed.
@Carmezim Carmezim changed the title Error after TF v1.4 upgrade Unable to run TensorBoard TF v1.4 upgrade Nov 21, 2017
@Carmezim Carmezim changed the title Unable to run TensorBoard TF v1.4 upgrade Unable to run TensorBoard after TF v1.4 upgrade Nov 21, 2017
@jart jart self-assigned this Nov 21, 2017
@jart
Copy link
Contributor

jart commented Nov 21, 2017

This should only impact tf-nightly users. Quick fix is pip install --upgrade tb-nightly. Assuming tensorflow/tensorflow#14741 is merged (which causes tf-nightly to depend on tb-nightly [only automated yesterday]), this issue shall be fixed at approximately the witching hour when tf-nightly 20171122 is loosed. Therefore I'm going to tentatively close this issue. If anything should go wrong, please leave a comment and I'll reopen.

@jart jart closed this as completed Nov 21, 2017
@Carmezim
Copy link
Author

Thank you @jart! Nice improvement on the nightly build :)

@Adeyinka-hub
Copy link

UnparsedFlagAccessError: Trying to access flag --preserve_unused_tokens before flags were parsed.
Is there any way i can get rid of this error please.

@Adeyinka-hub
Copy link

After running this codes below:

Tokenised sample of the first training set observation looks like

print(tokenizer.tokenize(train_InputExamples.iloc[0].text_a))

Here is the output error:

UnparsedFlagAccessError Traceback (most recent call last)
in
1 # Tokenised sample of the first training set observation looks like
----> 2 print(tokenizer.tokenize(train_InputExamples.iloc[0].text_a))

/opt/conda/lib/python3.7/site-packages/bert/tokenization.py in tokenize(self, text)
190 def tokenize(self, text):
191 split_tokens = []
--> 192 for token in self.basic_tokenizer.tokenize(text):
193 if preserve_token(token, self.vocab):
194 split_tokens.append(token)

/opt/conda/lib/python3.7/site-packages/bert/tokenization.py in tokenize(self, text)
235 split_tokens = []
236 for token in orig_tokens:
--> 237 if preserve_token(token, self.vocab):
238 split_tokens.append(token)
239 continue

/opt/conda/lib/python3.7/site-packages/bert/tokenization.py in preserve_token(token, vocab)
39 def preserve_token(token, vocab):
40 """Returns True if the token should forgo tokenization and be preserved."""
---> 41 if not FLAGS.preserve_unused_tokens:
42 return False
43 if token not in vocab:

/opt/conda/lib/python3.7/site-packages/absl/flags/_flagvalues.py in getattr(self, name)
496 # get too much noise.
497 logging.error(error_message)
--> 498 raise _exceptions.UnparsedFlagAccessError(error_message)
499
500 def setattr(self, name, value):

UnparsedFlagAccessError: Trying to access flag --preserve_unused_tokens before flags were parsed.

@psybuzz
Copy link
Contributor

psybuzz commented Jan 23, 2021

@Adeyinka-hub thanks for posting the error output. Based on the trace, it looks like the error you are seeing is more related to the 'bert' package than 'tensorboard'.

You may wish to follow google-research/bert#1133, which seems similar to the issue you report.

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

No branches or pull requests

4 participants