platform/upstream/tensorflow.git
7 years agoCorrectly incref items put into the tuple to keep msan happy.
Akshay Modi [Tue, 23 Jan 2018 20:01:11 +0000 (12:01 -0800)]
Correctly incref items put into the tuple to keep msan happy.

PiperOrigin-RevId: 182970703

7 years ago[XLA] Remove LiteralTestUtil::EqualTuple / NearTuple.
Justin Lebar [Tue, 23 Jan 2018 19:46:18 +0000 (11:46 -0800)]
[XLA] Remove LiteralTestUtil::EqualTuple / NearTuple.

Instead, simply DTRT when you pass a tuple to Equal/Near.

PiperOrigin-RevId: 182968283

7 years agoAdd `tf.contrib.distributions.Autoregressive`.
Joshua V. Dillon [Tue, 23 Jan 2018 19:37:58 +0000 (11:37 -0800)]
Add `tf.contrib.distributions.Autoregressive`.

PiperOrigin-RevId: 182966827

7 years agoMake feature_column_test.py run with the C API enabled.
Skye Wanderman-Milne [Tue, 23 Jan 2018 19:23:35 +0000 (11:23 -0800)]
Make feature_column_test.py run with the C API enabled.

I only enabled running the C API with test classes that other testing
found failures in to avoid increasing the test time unnecessarily.

PiperOrigin-RevId: 182964349

7 years agoMoves batch ops to core and exposes tf.contrib.batching
Alexandre Passos [Tue, 23 Jan 2018 19:20:29 +0000 (11:20 -0800)]
Moves batch ops to core and exposes tf.contrib.batching

PiperOrigin-RevId: 182963906

7 years agoRun TF opensource presubmits with sanybridge CPU optimizations.
Gunhan Gulsoy [Tue, 23 Jan 2018 19:09:26 +0000 (11:09 -0800)]
Run TF opensource presubmits with sanybridge CPU optimizations.

PiperOrigin-RevId: 182961789

7 years agoTFE usability: Implement `ndim` for `EagerTensor`+NumPy compatibility
Akshay Agrawal [Tue, 23 Jan 2018 19:05:50 +0000 (11:05 -0800)]
TFE usability: Implement `ndim` for `EagerTensor`+NumPy compatibility

Third party libraries like matplotlib often access `ndim`.

PiperOrigin-RevId: 182961097

7 years agoRemoved unecessary dependency
Benoit Steiner [Tue, 23 Jan 2018 18:59:00 +0000 (10:59 -0800)]
Removed unecessary dependency

PiperOrigin-RevId: 182959711

7 years agoIncrease shard count of tensorflow/contrib/learn:linear_test to avoid test timeouts.
A. Unique TensorFlower [Tue, 23 Jan 2018 18:19:19 +0000 (10:19 -0800)]
Increase shard count of tensorflow/contrib/learn:linear_test to avoid test timeouts.

The test tensorflow/contrib/learn:linear_test has been getting flaky timeouts t
a low rate for some time, but they increased greatly under the address
sanitizer due to a recent change there.

This CL increases the test's shard count to bring the time for each shard
well under the 5 minute timeout.

PiperOrigin-RevId: 182953078

7 years agoThe link translator expects "@{" for API links.
Mark Daoust [Tue, 23 Jan 2018 17:46:25 +0000 (09:46 -0800)]
The link translator expects "@{" for API links.

This is currently not rendering:

https://www.tensorflow.org/api_docs/python/tf/contrib/tpu/TPUEstimatorSpec

PiperOrigin-RevId: 182947562

7 years agoCorrect handling of dtype for Categorical sampling.
A. Unique TensorFlower [Tue, 23 Jan 2018 17:18:11 +0000 (09:18 -0800)]
Correct handling of dtype for Categorical sampling.

PiperOrigin-RevId: 182943806

7 years agoTurn off address sanitizer checking for tensorflow/python/kernel_tests:sparse_ops_test
A. Unique TensorFlower [Tue, 23 Jan 2018 08:10:52 +0000 (00:10 -0800)]
Turn off address sanitizer checking for tensorflow/python/kernel_tests:sparse_ops_test

It getting too many timeouts.

PiperOrigin-RevId: 182892876

7 years ago[XLA] Inline definitions of NativeToPrimitiveType<T>.
Justin Lebar [Tue, 23 Jan 2018 07:29:57 +0000 (23:29 -0800)]
[XLA] Inline definitions of NativeToPrimitiveType<T>.

These functions are hot in the evaluator, and that's silly, because
they're pure constants.  Just inline them.

PiperOrigin-RevId: 182889992

7 years ago[XLA] Speed up HloEvaluator's convolution routine.
Justin Lebar [Tue, 23 Jan 2018 06:56:04 +0000 (22:56 -0800)]
[XLA] Speed up HloEvaluator's convolution routine.

Skip two integer divisions when the window has no dilation.  This is
good for a ~30% speedup on my machine.

PiperOrigin-RevId: 182887749

7 years agoPuts the iterations_per_loop, which controls how many steps the TPU system to
Jianwei Xie [Tue, 23 Jan 2018 06:06:10 +0000 (22:06 -0800)]
Puts the iterations_per_loop, which controls how many steps the TPU system to
run for each training/evaluatoin loop, into local variable collection.

PiperOrigin-RevId: 182884955

7 years ago[XLA] Make kokoro happy in prng_test
Yunxing Dai [Tue, 23 Jan 2018 04:43:06 +0000 (20:43 -0800)]
[XLA] Make kokoro happy in prng_test

Open source builds don't support bit_cast yet, use reinterpret cast instead.
RELNOTES: n/a
PiperOrigin-RevId: 182879589

7 years agoAdding tf_export decorators/calls to TensorFlow functions and constants.
Anna R [Tue, 23 Jan 2018 04:07:42 +0000 (20:07 -0800)]
Adding tf_export decorators/calls to TensorFlow functions and constants.

PiperOrigin-RevId: 182877401

7 years agoGo: Update generated wrapper functions for TensorFlow ops.
A. Unique TensorFlower [Tue, 23 Jan 2018 02:45:56 +0000 (18:45 -0800)]
Go: Update generated wrapper functions for TensorFlow ops.

PiperOrigin-RevId: 182871435

7 years agoUpdate ops-related pbtxt files.
A. Unique TensorFlower [Tue, 23 Jan 2018 02:18:46 +0000 (18:18 -0800)]
Update ops-related pbtxt files.

PiperOrigin-RevId: 182868865

7 years ago_DefinedFunction.name should be a string.
Skye Wanderman-Milne [Tue, 23 Jan 2018 01:43:06 +0000 (17:43 -0800)]
_DefinedFunction.name should be a string.

With the C API enabled and python2, it was being set to a unicode
object.

PiperOrigin-RevId: 182865087

7 years agoReject retried RecvTensor requests.
Jeremy Lau [Tue, 23 Jan 2018 01:26:43 +0000 (17:26 -0800)]
Reject retried RecvTensor requests.

Retried RecvTensorRequests are problematic because a RecvTensor with no
corresponding sender will wait forever, and the tensor may have been delivered
to a previous retry.

This change adds a unique request_id to each RecvTensor request, and we check
these request_ids against a set of recent request_ids. If a request_id is in the
recent set, we reject the RecvTensor request.

PiperOrigin-RevId: 182863245

7 years agoAdding tf_export decorators/calls to TensorFlow functions and constants.
Anna R [Tue, 23 Jan 2018 01:16:44 +0000 (17:16 -0800)]
Adding tf_export decorators/calls to TensorFlow functions and constants.

PiperOrigin-RevId: 182862075

7 years agoOps to get and set individual elements of TensorLists, and their gradients.
Alexandre Passos [Tue, 23 Jan 2018 01:12:18 +0000 (17:12 -0800)]
Ops to get and set individual elements of TensorLists, and their gradients.

PiperOrigin-RevId: 182861559

7 years agoAdd SeparableConv1D layer and refactor SeparableConv2D to maximize code reuse and...
Francois Chollet [Tue, 23 Jan 2018 01:10:35 +0000 (17:10 -0800)]
Add SeparableConv1D layer and refactor SeparableConv2D to maximize code reuse and maintenability.

PiperOrigin-RevId: 182861372

7 years agoReplaced LOGs with NSLogs.
A. Unique TensorFlower [Tue, 23 Jan 2018 00:44:22 +0000 (16:44 -0800)]
Replaced LOGs with NSLogs.
Also inserted exit(-1) after LOG(FATAL)s.
Removed unused definition of CHECK macro.

PiperOrigin-RevId: 182857784

7 years agoAdds unit tests for squeeze, to test the case when all dims are 1.
A. Unique TensorFlower [Tue, 23 Jan 2018 00:41:37 +0000 (16:41 -0800)]
Adds unit tests for squeeze, to test the case when all dims are 1.

PiperOrigin-RevId: 182857374

7 years agoAdd functionality to include an optional additional header to be sent on every reques...
Frank Chen [Tue, 23 Jan 2018 00:28:47 +0000 (16:28 -0800)]
Add functionality to include an optional additional header to be sent on every request when using the GCS file system.

PiperOrigin-RevId: 182855525

7 years agoAdd file name and line number to statuses generated by OP_REQUIRES macros.
Jeremy Lau [Mon, 22 Jan 2018 23:54:33 +0000 (15:54 -0800)]
Add file name and line number to statuses generated by OP_REQUIRES macros.

PiperOrigin-RevId: 182850486

7 years ago[XLA][BF16] Add tests to demonstrate the brokeness of BF16 RNG functions in LLVM...
Yunxing Dai [Mon, 22 Jan 2018 23:10:08 +0000 (15:10 -0800)]
[XLA][BF16] Add tests to demonstrate the brokeness of BF16 RNG functions in LLVM backends.
- Added prng tests to demonstrate the brokeness of BF16 RNG functions in LLVM backends.

PiperOrigin-RevId: 182843680

7 years agoAdding tf_export decorators/calls to TensorFlow functions and constants.
Anna R [Mon, 22 Jan 2018 22:59:19 +0000 (14:59 -0800)]
Adding tf_export decorators/calls to TensorFlow functions and constants.

PiperOrigin-RevId: 182841644

7 years agoThread-safety for the TFE tape code.
Alexandre Passos [Mon, 22 Jan 2018 22:21:16 +0000 (14:21 -0800)]
Thread-safety for the TFE tape code.

In multithreaded python any call to a python API function can release the GIL,
so we should not assume our data structures haven't changed across calls to
the python API.

PiperOrigin-RevId: 182835555

7 years agoTrack swapping candidates directly in memory instead of annotating them in the graph
Benoit Steiner [Mon, 22 Jan 2018 21:58:08 +0000 (13:58 -0800)]
Track swapping candidates directly in memory instead of annotating them in the graph

PiperOrigin-RevId: 182831471

7 years agoBuildifier cleanup.
Yifei Feng [Mon, 22 Jan 2018 21:42:50 +0000 (13:42 -0800)]
Buildifier cleanup.

PiperOrigin-RevId: 182829120

7 years ago[TF:XLA] Bump open source llvm revision to r323081
Sanjoy Das [Mon, 22 Jan 2018 21:21:46 +0000 (13:21 -0800)]
[TF:XLA] Bump open source llvm revision to r323081

PiperOrigin-RevId: 182825537

7 years agoAllowing custom creators for variable_scope.variable()
Alexandre Passos [Mon, 22 Jan 2018 21:00:54 +0000 (13:00 -0800)]
Allowing custom creators for variable_scope.variable()

PiperOrigin-RevId: 182822430

7 years agoExtend the API with a pair of decorators that can convert functions inline.
A. Unique TensorFlower [Mon, 22 Jan 2018 19:27:33 +0000 (11:27 -0800)]
Extend the API with a pair of decorators that can convert functions inline.
Add logic to detect these decorators and treat them appropriately (e.g. when converting recursively, do all decorated functions as they are).

PiperOrigin-RevId: 182808673

7 years agoAdd new src targets for C API and native TF
A. Unique TensorFlower [Mon, 22 Jan 2018 19:18:44 +0000 (11:18 -0800)]
Add new src targets for C API and native TF

PiperOrigin-RevId: 182807258

7 years agoAdd support for tf.Example to saved_model_cli.
Yifei Feng [Mon, 22 Jan 2018 19:07:28 +0000 (11:07 -0800)]
Add support for tf.Example to saved_model_cli.
You can now pass tf.Example as inputs to with option --input_examples, for example:
--input_examples 'input_key=[{"age":[25],"education":["11th"]}]'

PiperOrigin-RevId: 182805401

7 years agotf.keras recurrent Layers: Fix doc strings on default activations
Shanqing Cai [Mon, 22 Jan 2018 19:02:40 +0000 (11:02 -0800)]
tf.keras recurrent Layers: Fix doc strings on default activations

* The default activation for input is `tanh`, not `linear`, as
  the previous doc string might mislead readers to think.
* Also clarify that the default activation for recurrent is
  `hard_sigmoid`.

PiperOrigin-RevId: 182804493

7 years agoFix TFLite Conv reference implementation
Yu-Cheng Ling [Mon, 22 Jan 2018 18:48:20 +0000 (10:48 -0800)]
Fix TFLite Conv reference implementation

PiperOrigin-RevId: 182802058

7 years agoAllow whitespace after commas in hparam strings.
A. Unique TensorFlower [Mon, 22 Jan 2018 18:36:05 +0000 (10:36 -0800)]
Allow whitespace after commas in hparam strings.

E.g., allow 'a=b, c=d' or 'a=b,\nc=d' in addition to just 'a=b,c=d'.

PiperOrigin-RevId: 182800230

7 years agoInternal change
A. Unique TensorFlower [Mon, 22 Jan 2018 18:19:07 +0000 (10:19 -0800)]
Internal change

PiperOrigin-RevId: 182797605

7 years agomnist and resnet eager examples avoiding optimizer.minimize
Alexandre Passos [Mon, 22 Jan 2018 17:47:55 +0000 (09:47 -0800)]
mnist and resnet eager examples avoiding optimizer.minimize

PiperOrigin-RevId: 182792844

7 years agoReducing op overhead for eager.
Akshay Modi [Mon, 22 Jan 2018 17:39:44 +0000 (09:39 -0800)]
Reducing op overhead for eager.

Benchmarks:
(new) tfe_py_fastpath_execute_matmul: 7.86213080088 walltime
(old) gen_math_ops_matmul: 11.2566947937 walltime

(The slowdown is due to adding the record_gradient callback)

This will be a 3-step process:

1. (This CL) Add a function that allows execution of an op on the fastpath.
2. Update python generation code to create 2 new python functions
(_op/_op_gradient_callback and _op_slowpath_fallback):
   -- first function (_op) checks if it is in graph mode, if so, do the normal
      thing, else call out to the function added in step 1.
   -- second function does the else part similar to today (calling out to
   args_to_matching_eager etc.)
3. Rename the first function generated above to be the canonical _op function.

PiperOrigin-RevId: 182791741

7 years agoMake array_ops_test.py work with the C API enabled.
Skye Wanderman-Milne [Mon, 22 Jan 2018 16:31:23 +0000 (08:31 -0800)]
Make array_ops_test.py work with the C API enabled.

I only enabled the test class that other testing identified needed changes.

PiperOrigin-RevId: 182783262

7 years agoImplement native support of CycleGAN in tf.contrib.gan
A. Unique TensorFlower [Mon, 22 Jan 2018 16:19:56 +0000 (08:19 -0800)]
Implement native support of CycleGAN in tf.contrib.gan

PiperOrigin-RevId: 182782072

7 years agoInternal cleanup
A. Unique TensorFlower [Mon, 22 Jan 2018 15:47:48 +0000 (07:47 -0800)]
Internal cleanup

PiperOrigin-RevId: 182777782

7 years agoReplace "Google Container Engine" by "Google Kubernetes Engine" in README.md.
A. Unique TensorFlower [Mon, 22 Jan 2018 14:39:21 +0000 (06:39 -0800)]
Replace "Google Container Engine" by "Google Kubernetes Engine" in README.md.

PiperOrigin-RevId: 182771284

7 years agoFix a bug in the associative & commutative rewrite in constant folding:
A. Unique TensorFlower [Sun, 21 Jan 2018 17:22:43 +0000 (09:22 -0800)]
Fix a bug in the associative & commutative rewrite in constant folding:
I finally tracked it down to the case where we do the transformation:

    //
    //                      +                +       = parent
    //                     / \              / \
    //                    C   +    -- >    X   +     = children
    //                       / \              / \
    //                      X   Y            C   Y   = leaves

when there exists a control dependency from the child '+' to C. This control dependency creates a cycle in the graph when X and C are simply swapped. We can fix it by moving the control dependency and anchoring it on Y instead (We still need it in case we are inside a frame).

PiperOrigin-RevId: 182705910

7 years ago[TF:XLA] Bump open source llvm revision to r323005
Benjamin Kramer [Sun, 21 Jan 2018 16:03:46 +0000 (08:03 -0800)]
[TF:XLA] Bump open source llvm revision to r323005

PiperOrigin-RevId: 182703514

7 years agoImprove error message in create_python_api.py. The new message would print
Anna R [Sun, 21 Jan 2018 04:34:12 +0000 (20:34 -0800)]
Improve error message in create_python_api.py. The new message would print
exact filenames that need to be added to the
tensorflow/tools/api/generator/BUILD file.

PiperOrigin-RevId: 182679235

7 years ago[XLA:GPU] Warn on more broken CUDA versions.
Justin Lebar [Sun, 21 Jan 2018 02:13:15 +0000 (18:13 -0800)]
[XLA:GPU] Warn on more broken CUDA versions.

We've received additional data on which CUDA versions contain a ptx
assembler bug that affects XLA.  Warn if you're using any of these.

PiperOrigin-RevId: 182675055

7 years agoUpdate XLA for LLVM r323001
Benjamin Kramer [Sat, 20 Jan 2018 18:50:16 +0000 (10:50 -0800)]
Update XLA for LLVM r323001

This will require an LLVM version bump

PiperOrigin-RevId: 182661291

7 years agoAdded BeamRoot to manage instances of BeamEntry for CTCBeamSearchDecoder
A. Unique TensorFlower [Sat, 20 Jan 2018 04:52:19 +0000 (20:52 -0800)]
Added BeamRoot to manage instances of BeamEntry for CTCBeamSearchDecoder
to avoid recursive destructor call.

PiperOrigin-RevId: 182625992

7 years agoTurn the op_performance_data proto lib into a header only library by default
Benoit Steiner [Sat, 20 Jan 2018 03:13:43 +0000 (19:13 -0800)]
Turn the op_performance_data proto lib into a header only library by default

PiperOrigin-RevId: 182621348

7 years agoAdd check for valid outfeed shape on outfeed creation and in HloVerifier.
Mark Heffernan [Sat, 20 Jan 2018 02:05:19 +0000 (18:05 -0800)]
Add check for valid outfeed shape on outfeed creation and in HloVerifier.

PiperOrigin-RevId: 182616345

7 years ago[XLA] Update R4 reduce window test cases.
A. Unique TensorFlower [Sat, 20 Jan 2018 01:18:25 +0000 (17:18 -0800)]
[XLA] Update R4 reduce window test cases.

PiperOrigin-RevId: 182612106

7 years agoAdd clif rules for function.proto.
Jacques Pienaar [Sat, 20 Jan 2018 00:55:11 +0000 (16:55 -0800)]
Add clif rules for function.proto.

PiperOrigin-RevId: 182609604

7 years agoMake sure the same rewrite is not performed multiple times in ArithmeticOptimizer...
A. Unique TensorFlower [Sat, 20 Jan 2018 00:54:39 +0000 (16:54 -0800)]
Make sure the same rewrite is not performed multiple times in ArithmeticOptimizer, and that added nodes are unique.
A couple of minor cleanups.

PiperOrigin-RevId: 182609552

7 years agoReport incompatible shapes in case of check failure.
Jacques Pienaar [Fri, 19 Jan 2018 23:42:39 +0000 (15:42 -0800)]
Report incompatible shapes in case of check failure.

PiperOrigin-RevId: 182600051

7 years agoAutomated g4 rollback of changelist 182559231
A. Unique TensorFlower [Fri, 19 Jan 2018 23:31:24 +0000 (15:31 -0800)]
Automated g4 rollback of changelist 182559231

PiperOrigin-RevId: 182598631

7 years ago[XLA] Add xla_dump_prepass_hlo_proto_to debug flag
Nick Desaulniers [Fri, 19 Jan 2018 23:01:35 +0000 (15:01 -0800)]
[XLA] Add xla_dump_prepass_hlo_proto_to debug flag

Add xla_dump_prepass_hlo_proto_to debug flag for dumping HLO protos *BEFORE*
running HLO passes, which will perform backend specific optimizations.

PiperOrigin-RevId: 182594324

7 years agoTFLite export optional tensor as -1 id.
Zhixian Yan [Fri, 19 Jan 2018 22:51:11 +0000 (14:51 -0800)]
TFLite export optional tensor as -1 id.

PiperOrigin-RevId: 182592943

7 years ago[tf.data] Minor fix for saveable MapDataset and ParallelMapDataset.
Shivani Agrawal [Fri, 19 Jan 2018 22:38:45 +0000 (14:38 -0800)]
[tf.data] Minor fix for saveable MapDataset and ParallelMapDataset.

PiperOrigin-RevId: 182591174

7 years agoPublish TPU Estimators Docs on github
A. Unique TensorFlower [Fri, 19 Jan 2018 22:05:20 +0000 (14:05 -0800)]
Publish TPU  Estimators Docs on github

PiperOrigin-RevId: 182585909

7 years agoFilling in some holes in C64 support with Literals.
Brian Patton [Fri, 19 Jan 2018 22:03:27 +0000 (14:03 -0800)]
Filling in some holes in C64 support with Literals.

PiperOrigin-RevId: 182585597

7 years ago[XLA] Simplify trivial pad/reduce-window combos into broadcasts.
Chris Leary [Fri, 19 Jan 2018 22:01:29 +0000 (14:01 -0800)]
[XLA] Simplify trivial pad/reduce-window combos into broadcasts.

PiperOrigin-RevId: 182585236

7 years agoUpdate pin for bazel-toolchains to latest version
A. Unique TensorFlower [Fri, 19 Jan 2018 21:05:53 +0000 (13:05 -0800)]
Update pin for bazel-toolchains to latest version

https://github.com/bazelbuild/bazel-toolchains/releases/tag/f3b0970

PiperOrigin-RevId: 182576952

7 years ago[TF:XLA] Improve the error message when ComputeConstant fails.
Peter Hawkins [Fri, 19 Jan 2018 20:09:13 +0000 (12:09 -0800)]
[TF:XLA] Improve the error message when ComputeConstant fails.

Make comment in computation_builder.h more precise.

PiperOrigin-RevId: 182569583

7 years agoAdd support for time_major shape format to the sequential RNN Op in TF Lite.
A. Unique TensorFlower [Fri, 19 Jan 2018 20:08:47 +0000 (12:08 -0800)]
Add support for time_major shape format to the sequential RNN Op in TF Lite.

This option, if set, changes the shape format of the inputs and outputs to
[max_time, batch_size, depth]. If false, it uses [batch_size, max_time, depth].
By default, it is set to false.

PiperOrigin-RevId: 182569507

7 years agoHandling resource captures when defining functions.
Alexandre Passos [Fri, 19 Jan 2018 20:03:50 +0000 (12:03 -0800)]
Handling resource captures when defining functions.

PiperOrigin-RevId: 182568701

7 years agoMove layers_dense_variational_impl.py to layers_dense_variational.py.
Dustin Tran [Fri, 19 Jan 2018 20:00:33 +0000 (12:00 -0800)]
Move layers_dense_variational_impl.py to layers_dense_variational.py.

PiperOrigin-RevId: 182568201

7 years agoChange deprecated keep_dims parameter to keepdims.
A. Unique TensorFlower [Fri, 19 Jan 2018 19:59:42 +0000 (11:59 -0800)]
Change deprecated keep_dims parameter to keepdims.

PiperOrigin-RevId: 182568093

7 years ago [tpu:profiler] Do not generate output files from other cloud tools if no trace...
A. Unique TensorFlower [Fri, 19 Jan 2018 19:49:29 +0000 (11:49 -0800)]
   [tpu:profiler] Do not generate output files from other cloud tools if no trace is collected.

PiperOrigin-RevId: 182566765

7 years ago[TF:XLA] Bump open source llvm revision to r322942
Sanjoy Das [Fri, 19 Jan 2018 19:46:55 +0000 (11:46 -0800)]
[TF:XLA] Bump open source llvm revision to r322942

PiperOrigin-RevId: 182566386

7 years agoAdd convolutional Flipout layers.
Dustin Tran [Fri, 19 Jan 2018 19:04:26 +0000 (11:04 -0800)]
Add convolutional Flipout layers.

PiperOrigin-RevId: 182559534

7 years agoCorrect handling of dtype for multinomial sampling.
A. Unique TensorFlower [Fri, 19 Jan 2018 19:02:50 +0000 (11:02 -0800)]
Correct handling of dtype for multinomial sampling.

PiperOrigin-RevId: 182559231

7 years agoAdd option for loop unrolling in MaskedAutoregressiveFlow bijector.
A. Unique TensorFlower [Fri, 19 Jan 2018 19:01:45 +0000 (11:01 -0800)]
Add option for loop unrolling in MaskedAutoregressiveFlow bijector.

PiperOrigin-RevId: 182559030

7 years agoFixes issue with using lookup ops in datasets from eager.
Alexandre Passos [Fri, 19 Jan 2018 18:36:05 +0000 (10:36 -0800)]
Fixes issue with using lookup ops in datasets from eager.

Addresses issue #16160

PiperOrigin-RevId: 182554969

7 years agoFixes #12466. Fix getfile in cases when .py files aren't available (only .pyc files are
Anna R [Fri, 19 Jan 2018 18:32:15 +0000 (10:32 -0800)]
Fixes #12466. Fix getfile in cases when .py files aren't available (only .pyc files are
used).

PiperOrigin-RevId: 182554325

7 years agoFix documentation typo.
A. Unique TensorFlower [Fri, 19 Jan 2018 17:53:10 +0000 (09:53 -0800)]
Fix documentation typo.

PiperOrigin-RevId: 182548006

7 years agoChange deprecated dim parameter to axis.
A. Unique TensorFlower [Fri, 19 Jan 2018 17:46:59 +0000 (09:46 -0800)]
Change deprecated dim parameter to axis.

PiperOrigin-RevId: 182547126

7 years agoImproved detection of swappable nodes
Benoit Steiner [Fri, 19 Jan 2018 17:12:34 +0000 (09:12 -0800)]
Improved detection of swappable nodes

PiperOrigin-RevId: 182542749

7 years ago[TF:XLA] Include a summary of the TF operator when TF -> XLA compilation fails.
Peter Hawkins [Fri, 19 Jan 2018 17:06:40 +0000 (09:06 -0800)]
[TF:XLA] Include a summary of the TF operator when TF -> XLA compilation fails.

PiperOrigin-RevId: 182542114

7 years agoUpdated the version of downloadable chromium's clang toolchain
Ilya Biryukov [Fri, 19 Jan 2018 11:11:14 +0000 (03:11 -0800)]
Updated the version of downloadable chromium's clang toolchain

PiperOrigin-RevId: 182511847

7 years agoFix typo in MklSubAllocator::ClearStats()
A. Unique TensorFlower [Fri, 19 Jan 2018 07:21:48 +0000 (23:21 -0800)]
Fix typo in MklSubAllocator::ClearStats()

PiperOrigin-RevId: 182492508

7 years agoSupport writing np.ndarray as tensors in Summary proto.
A. Unique TensorFlower [Fri, 19 Jan 2018 02:54:45 +0000 (18:54 -0800)]
Support writing np.ndarray as tensors in Summary proto.

PiperOrigin-RevId: 182474037

7 years agoScript to create ApiDef files automatically based on OpDef.
Anna R [Fri, 19 Jan 2018 01:16:06 +0000 (17:16 -0800)]
Script to create ApiDef files automatically based on OpDef.

PiperOrigin-RevId: 182463327

7 years agoReshaping vars correctly in _compute_fraction_of_zero.
A. Unique TensorFlower [Fri, 19 Jan 2018 01:02:02 +0000 (17:02 -0800)]
Reshaping vars correctly in _compute_fraction_of_zero.

PiperOrigin-RevId: 182461459

7 years agoAvoid use-after-free in eager tape code.
Alexandre Passos [Fri, 19 Jan 2018 00:51:40 +0000 (16:51 -0800)]
Avoid use-after-free in eager tape code.

PiperOrigin-RevId: 182460292

7 years ago[TF:XLA] Make ResizeBilinear and ResizeBilinearGrad faster for images of size 2^x+1.
A. Unique TensorFlower [Fri, 19 Jan 2018 00:20:14 +0000 (16:20 -0800)]
[TF:XLA] Make ResizeBilinear and ResizeBilinearGrad faster for images of size 2^x+1.

PiperOrigin-RevId: 182456096

7 years agoFix some (re)shaping issues.
A. Unique TensorFlower [Fri, 19 Jan 2018 00:03:32 +0000 (16:03 -0800)]
Fix some (re)shaping issues.

PiperOrigin-RevId: 182453707

7 years agoRemove extra repeat in tf.data.Dataset documentation.
A. Unique TensorFlower [Thu, 18 Jan 2018 23:50:21 +0000 (15:50 -0800)]
Remove extra repeat in tf.data.Dataset documentation.
END_PUBLIC

Unless I am missing something:

BEGIN_PUBLIC
If num_epochs is 0, this isn't needed anyway; and if num_epochs > 0 then this will be buggy, because it will cause the output dataset to repeat for more than num_epochs.

PiperOrigin-RevId: 182451811

7 years agoUpdate tensorboard dependency to minimum of 0.4.0
Nick Felt [Thu, 18 Jan 2018 23:50:16 +0000 (15:50 -0800)]
Update tensorboard dependency to minimum of 0.4.0

This should address https://github.com/tensorflow/tensorboard/issues/877.

PiperOrigin-RevId: 182451796

7 years agoHandle case when buffer_size is larger than total dataset size in shuffle dataset op.
Saurabh Saxena [Thu, 18 Jan 2018 23:27:12 +0000 (15:27 -0800)]
Handle case when buffer_size is larger than total dataset size in shuffle dataset op.
Currently ShuffleDatasetOpBase::GetNext throws a "Attempted to repeat an empty dataset infinitely." if the number of outputs produced from the dataset are < buffer_size.
Usually the buffer size is set to <= total dataset size so we never run into this.

PiperOrigin-RevId: 182448427

7 years agoEntice TensorFlow to swap data out of GPU memory sooner
Benoit Steiner [Thu, 18 Jan 2018 23:08:48 +0000 (15:08 -0800)]
Entice TensorFlow to swap data out of GPU memory sooner

PiperOrigin-RevId: 182445531

7 years agoAdd a convenient function that makes an HloProto from an HloModule.
A. Unique TensorFlower [Thu, 18 Jan 2018 22:28:45 +0000 (14:28 -0800)]
Add a convenient function that makes an HloProto from an HloModule.

PiperOrigin-RevId: 182438633

7 years agoFixed Eigen-version Conv2DBackpropInput kernel, marked with "eigen_tensor".
Sung Jin Hwang [Thu, 18 Jan 2018 22:24:50 +0000 (14:24 -0800)]
Fixed Eigen-version Conv2DBackpropInput kernel, marked with "eigen_tensor".

LaunchConv2DBackpropInputOp, a template functor class used in
Conv2DFastBackpropInputOp class was specialized in a wrong place, in
conv_grad_filter_ops.cc (ODR violation). This caused wrong functor to be called
inside the op kernel class, because the correct functor definition was overriden
by a wrong specialization. The functor class that should have been specialized
in conv_grad_filter_ops.cc was LaunchConv2DBackpropFilterOp.

PiperOrigin-RevId: 182438025

7 years agoUse snake-case name when generating @tf_export decorator in python_op_gen.cc.
Anna R [Thu, 18 Jan 2018 22:20:56 +0000 (14:20 -0800)]
Use snake-case name when generating @tf_export decorator in python_op_gen.cc.

PiperOrigin-RevId: 182437341

7 years agoMake bfloat16 work correctly with matmul
A. Unique TensorFlower [Thu, 18 Jan 2018 22:20:14 +0000 (14:20 -0800)]
Make bfloat16 work correctly with matmul

PiperOrigin-RevId: 182437226