Skip to content

Conversation

@av8ramit
Copy link
Contributor

Updating the EventsWriter import to _pywrap_events_writer from pywrap_tensorflow.

  • Motivation for features / changes
    This is part of a larger effort in TensorFlow to break up pywrap_tensorflow and migrate from SWIG to pybind11. Please refer to this RFC for more information.

  • Technical description of changes
    Changes the import package to point to the new one.

  • Detailed steps to verify changes work correctly (as executed by you)

This is an example of a pywrap import and how it works. Unfortunately I cannot provide an exact EventsWriter example, because the nightly binary has not been built yet.

In [1]: from tensorflow.python import _pywrap_utils                                                                                                                                                                

In [2]: _pywrap_utils.IsSequence(1)                                                                                                                                                                                
Out[2]: False

In [3]: _pywrap_utils.IsSequence([1])                                                                                                                                                                              
Out[3]: True

NOTE: Please only submit this PR if you are pulling TensorFlow from tf-nightly-2.0-preview. If you are using tf-nightly, that has not been updated since 08/21 and is still using old code.

Copy link
Contributor

@wchargin wchargin left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

For context, this is for compatibility with an upstream commit:
tensorflow/tensorflow@5a9b155

Confirmed fixed after test sync (Googlers, see http://cl/270160498).

Thanks!

@wchargin wchargin merged commit 8111888 into tensorflow:master Sep 20, 2019
tensorflow-copybara pushed a commit to tensorflow/tensorflow that referenced this pull request Sep 24, 2019
…nstead of swig. This is part of a larger effort to deprecate swig and eventually with modularization break pywrap_tensorflow into smaller components. It will also make exporting C++ ops to Python significantly easier. XLA is using the pybind11 macros already. Please refer to https://github.com/tensorflow/community/blob/master/rfcs/20190208-pybind11.md for more information.

We are slightly changing the behavior of EventsWriter. Rather than returning a bad status when writing to a deleted file which is often ignored by the user, we are removing the FileStillExists check.

TensorBoard has already been prepared for this change via: tensorflow/tensorboard#2683

PiperOrigin-RevId: 270945727
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants