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

Plugin tabs disabled inside TB v1.15 when JS compilation is disabled #2687

Open
ceevee830 opened this issue Sep 21, 2019 · 10 comments
Open

Plugin tabs disabled inside TB v1.15 when JS compilation is disabled #2687

ceevee830 opened this issue Sep 21, 2019 · 10 comments

Comments

@ceevee830
Copy link

While porting our plugin to TB v1.15, I'm noticing that both plugin tabs in the plugin bar are disabled. I've stubbed out the GPU_SUMMARY dashboard to try and remove any environmental issues. Thoughts?

image

tf-gpu-dashboard.html

<link rel="import" href="../tf-imports/polymer.html" />

<dom-module id="tf-gpu-summary-dashboard">
  <template>
    <h1>INSIDE tf-gpu-summary-dashboard</h1>
  </template>
  <script>

    Polymer({
      is: 'tf-gpu-summary-dashboard',
    });

  </script>
</dom-module>

Environment information (required)

Diagnostics

Diagnostics output
--- check: autoidentify
INFO: diagnose_tensorboard.py version 393931f9685bd7e0f3898d7dcdf28819fef54c43

--- check: general
INFO: sys.version_info: sys.version_info(major=3, minor=5, micro=2, releaselevel='final', serial=0)
INFO: os.name: posix
INFO: os.uname(): posix.uname_result(sysname='Linux', nodename='openwater-dt1', release='4.15.0-62-generic', version='#69~16.04.1-Ubuntu SMP Fri Sep 6 02:43:35 UTC 2019', machine='x86_64')
INFO: sys.getwindowsversion(): N/A

--- check: package_management
INFO: has conda-meta: False
INFO: $VIRTUAL_ENV: None

--- check: installed_packages
INFO: installed: tensorboard==1.15.0
INFO: installed: tensorflow-gpu==1.15.0rc1
INFO: installed: tensorflow-estimator==1.15.1

--- check: tensorboard_python_version
INFO: tensorboard.version.VERSION: '1.15.0'

--- check: tensorflow_python_version
INFO: tensorflow.__version__: '1.15.0-rc1'
INFO: tensorflow.__git_version__: 'v1.15.0-rc0-27-gea93078'

--- check: tensorboard_binary_path
INFO: which tensorboard: b'/usr/local/bin/tensorboard\n'

--- check: readable_fqdn
INFO: socket.getfqdn(): 'openwater-dt1'

--- check: stat_tensorboardinfo
INFO: directory: /tmp/.tensorboard-info
INFO: os.stat(...): os.stat_result(st_mode=16895, st_ino=26887361, st_dev=2050, st_nlink=2, st_uid=1000, st_gid=1000, st_size=4096, st_atime=1568733863, st_mtime=1569025370, st_ctime=1569025370)
INFO: mode: 0o40777

--- check: source_trees_without_genfiles
INFO: tensorboard_roots (1): ['/usr/local/lib/python3.5/dist-packages']; bad_roots (0): []

--- check: full_pip_freeze
INFO: pip freeze --all:
absl-py==0.7.0
apt-xapian-index==0.47
apturl==0.5.2
argcomplete==0.8.1
astor==0.7.1
chardet==2.3.0
command-not-found==0.3
defer==1.0.6
gast==0.2.2
google-pasta==0.1.7
grpcio==1.18.0
h5py==2.9.0
Keras-Applications==1.0.6
Keras-Preprocessing==1.0.9
language-selector==0.1
Markdown==3.0.1
mock==2.0.0
numpy==1.16.2
opt-einsum==3.0.1
pbr==5.1.3
pexpect==4.0.1
Pillow==3.1.2
pip==19.2.3
progressbar==2.3
protobuf==3.6.1
ptyprocess==0.5
pycups==1.9.73
pycurl==7.43.0
pygobject==3.20.0
python-apt==1.1.0b1+ubuntu0.16.4.5
python-debian==0.1.27
python-gnupg==0.3.8
python-systemd==231
pyxdg==0.25
PyYAML==3.11
reportlab==3.3.0
requests==2.9.1
screen-resolution-extra==0.0.0
setuptools==41.2.0
six==1.12.0
ssh-import-id==5.5
tensorboard==1.15.0
tensorflow-estimator==1.15.1
tensorflow-gpu==1.15.0rc1
termcolor==1.1.0
ubuntu-drivers-common==0.0.0
Ubuntu-Make==19.6
ufw==0.35
unattended-upgrades==0.1
urllib3==1.13.1
virtualenv==15.0.1
Werkzeug==0.14.1
wheel==0.33.1
wrapt==1.11.2
xkit==0.0.0

Next steps

No action items identified. Please copy ALL of the above output,
including the lines containing only backticks, into your GitHub issue
or comment. Be sure to redact any sensitive information.

Steps to reproduce (required)

cvinson@openwater-dt1:~/cvinson-dev/gitlab/tensorflow-tensorboard/tensorboard$ bazel run tensorboard --verbose_failures -- --logdir ~/cvinson-dev/stories/MobilenetV2/
INFO: Analyzed target //tensorboard:tensorboard (0 packages loaded, 0 targets configured).
INFO: Found 1 target...
Target //tensorboard:tensorboard up-to-date:
  bazel-bin/tensorboard/tensorboard
INFO: Elapsed time: 0.206s, Critical Path: 0.00s
INFO: 0 processes.
INFO: Build completed successfully, 1 total action
INFO: Build completed successfully, 1 total action
WARNING: Logging before flag parsing goes to stderr.
W0920 17:26:20.591699 140368825038592 __init__.py:329] Limited tf.compat.v2.summary API due to missing TensorBoard installation.
TensorBoard 1.15.0 at http://openwater-dt1:6007/ (Press CTRL+C to quit)
@psybuzz
Copy link
Contributor

psybuzz commented Sep 21, 2019

Hello! I've noticed this on a local build, usually after setting "compile = False" in "tensorboard/components/BUILD". It's kind of frustrating.
In your repro, did you alter any of the BUILD flags?

If not, could you please open the DevTools Console and share any errors with us, if any?

@ceevee830
Copy link
Author

ceevee830 commented Sep 22, 2019

That's it! Changing that compile flag from True to False enabled the tabs in the plugin toolbar. Thanks.

Any chance we could get this in the TB v1.15 release? I'd like to have that flag False to enhance debugging and reduce compile time (ie, the Vulcanizing step takes 20+ seconds each build). Thanks again.

@nfelt
Copy link
Contributor

nfelt commented Sep 26, 2019

Compilation has to be on for the What-If Tool to work, so we can't disable it by default (and vulcanization still happens even if compilation is off; they're not quite the same thing). You can just change the flag value locally though.

@ceevee830
Copy link
Author

Hi Nick, the vulcanzing of tensorboard.html takes ~25 seconds each build and impacts my productivity.
Vulcanizing /tensorboard.html; 25s linux-sandbox.
How can I get the What-If-Tool to work and remove the long vulcanizing step each time I call bazel build?

@nfelt
Copy link
Contributor

nfelt commented Sep 26, 2019

Vulcanization and closure compilation are different steps. What-If Tool is the only thing that needs closure compilation, so you can set compile to false locally while you develop and then restore it to true afterwards.

Vulcanization is much more deeply enmeshed in how TensorBoard's frontend build system works, it's not just the What-If Tool that needs it. If it were easy to eliminate we would have done so already.

@ceevee830
Copy link
Author

Nick, which files do I edit and how in TB v1.15 to 1) get bazel to omit the Vulcanizing /tensorboard.html; 25s linux-sandbox step, and 2) have the dashboard tabs enabled?

@nfelt
Copy link
Contributor

nfelt commented Sep 26, 2019

As I just explained, there isn't a way to omit the vulcanization step when building TensorBoard. It's mandatory. JS compilation is a separate step.

In your earlier comment, you said "Changing that compile flag from True to False enabled the tabs in the plugin toolbar." Is this correct, or did you mean to say that changing it from False to True enabled the tabs?

If the latter, then the issue is that with compilation disabled (for speed of development), the plugin tab is rendering as disabled. Is that correct?

I don't have a solution to that issue, but we may be able to figure something out. In general though TensorBoard is not necessarily going to work completely without the compilation step, as slow as that is.

@ceevee830
Copy link
Author

In TB v1.14, changing tensorboard_html_binary.compile from True to False (as recommended by Gal) had two benefits: 1) the vulcanization step was omitted, and 2) the dashboard tabs were enabled.
In TB v1.15, changing it from True to False disables the dashboard tabs. When set to True, the tabs are enabled but it takes ~25 seconds for bazel to complete.

@ceevee830
Copy link
Author

Nick is there any combination of parameters or settings that enables the dashboard tabs and omits the ~25 vulcanizing step?

@nfelt nfelt changed the title Plugin tabs disabled inside TB v1.15 Plugin tabs disabled inside TB v1.15 when JS compilation is disabled Oct 1, 2019
@nfelt
Copy link
Contributor

nfelt commented Oct 1, 2019

Not right now, no. There is probably a way to get the tabs to work again even when JS compilation is disabled, but it would require some investigation, and as I said we ship with compilation set to True so support for making TB work with it off is best-effort.

My best recommendation right now is to do the development that requires fast iteration outside TensorBoard (the same way you would develop standalone HTML/JS independently). The point of the dynamic plugin system is to make it easy to then take that and deploy it inside TensorBoard without modification. Then build TensorBoard itself with compile = True.

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