-
Notifications
You must be signed in to change notification settings - Fork 74.4k
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
Provide a way to build a Tensorflow wheel without a dependency on Tensorboard #20280
Comments
Hi, @orf. I don't believe that TensorBoard will ever be separated from TensorFlow. The TensorFlow team has worked hard to keep the package small in size, and they want TensorFlow to come with a nice visualization tool. Please see tensorflow#12567. It doesn't solve your question, but it may be useful in deciding how to continue. |
Hey @marshalhayes, thank you for your quick reply. Let me just elaborate a bit. I have no problem with Tensorboard being bundled with the default Tensorflow package but in the context of a server environment specifically I've elaborated on a few issues below. I only ask for the idea that when building a custom Tensorflow package the option is given to disable the dependency link somehow.
All of these are exacerbated in my mind as Tensorboard is not used or required in the situations we are using it. As we are building a custom Tensorflow package that matches our CPU features I would simply love a build flag to disable the dependency link. |
Nagging Assignee @michaelisard: It has been 14 days with no activity and this issue has an assignee. Please update the label and/or status accordingly. |
This would be an opportunity to create two packages: tensorflow-core, which only installs tensorflow (and which may in fact result in some tensorflow python endpoints not working) and tensorflow (which is a virtual package that has dependencies on tensorflow-core and tensorboard. In the future, we may split tensorflow-core into more packages. I am not fundamentally opposed to this, but
Most importantly though, I am hesitant to offer another package that people will come to depend on for a fixed set of functionality. For example, I wouldn't want people to get used to tensorflow-core coming with Estimators. We're in the process of separating tf.estimator into its own package. In the future, more such splits may happen (kernel libraries, ops libraries), and I think the exact dependency tree of all those packages needs to be an implementation detail. Maybe that's ok by calling them tensorflow_private_seekrit_kernels_do_not_depend_directly_on_this, but I think depending directly on this is exactly what you want to do. I think a tensorflow-server-only package which only contains what you need to run a tensorflow server is really what you want? As in, none of the Python API either? |
I think this might be going too far, all I'm asking for is a You distribute Tensorflow as a lowest common denominator binary. Ok, that's fine and makes sense. So we should build it ourselves for our specific CPU features when running it at any scale. Ok, that's also fine and makes sense. But we should always always always include Tensorboard as a dependency? That's not fine, especially when it leads to conflicting dependencies and those dependencies have known CVE's against them. I'd love to switch to tensorflow-server, and I'm pushing for it, but... you know. Time. As a side note, the new Tensorflow release (congratulations!) triggers a defect in the |
Yeah, that's reasonable. @yifeif do you have a sense of how easy this is to achieve using bazel? I suppose we could give setup.py a flag which we set using some bazel option, or something. Or, we could simply add a flag to setup.py, and you execute setup.py bdist_wheel yourself? That's definitely feasible and looks easy to do. I've added contributions welcome if you want to propose a specific way to do it. |
Yep, that's exactly what I am looking for. Thanks! Maybe this is a separate ticket but customizing the name of the package via a bazel flag would be awesome as well. Currently I am relying on a particular bash script that is sourced before I'm currently a bit short on time but I will try and propose a PR to do both, if that is OK? |
That sounds good, thanks! |
Please remove the assignee, as this issue is inviting external contributions. Otherwise, remove the |
Hi @orf! Please post on TF-Forum for further assistance. Thank you! |
This issue has been automatically marked as stale because it has no recent activity. It will be closed if no further activity occurs. Thank you. |
bump |
Closing as stale. Please reopen if you'd like to work on this further. |
Hi @tekumara ! |
System information
Describe the problem
When building a custom Tensorflow wheel from source there is currently no way to disable the resulting wheels dependency on
tensorboard
. Tensorboard is great during development but is not useful when running in a headless server environment. It brings with it a large number of dependencies, and as I believe a custom tensorflow build is likely to be used in this kind of environment and it would be great to be able to disable theinstall_requires
dependency on tensorboard in this case.The text was updated successfully, but these errors were encountered: