platform/upstream/tensorflow.git
7 years agorename files
Mark Daoust [Wed, 20 Dec 2017 15:24:29 +0000 (07:24 -0800)]
rename files

PiperOrigin-RevId: 179683700

7 years agoReplace std::pow with MathUtil::IPow when the exponent is a non-negative integer.
A. Unique TensorFlower [Wed, 20 Dec 2017 14:47:44 +0000 (06:47 -0800)]
Replace std::pow with MathUtil::IPow when the exponent is a non-negative integer.

Includes minor test cleanup.

PiperOrigin-RevId: 179680628

7 years agoRemove unused BUILD dependencies
A. Unique TensorFlower [Wed, 20 Dec 2017 14:46:40 +0000 (06:46 -0800)]
Remove unused BUILD dependencies

PiperOrigin-RevId: 179680552

7 years agoPiperOrigin-RevId: 179639611
Raghuraman Krishnamoorthi [Wed, 20 Dec 2017 04:38:51 +0000 (20:38 -0800)]
PiperOrigin-RevId: 179639611

7 years ago[TF:XLA] Move ShardingBuilder out of computation_builder.h
A. Unique TensorFlower [Wed, 20 Dec 2017 13:35:03 +0000 (05:35 -0800)]
[TF:XLA] Move ShardingBuilder out of computation_builder.h

ShardingBuilder does not belong in computation_builder.h - its presence there is puzzling and unintuitive.

PiperOrigin-RevId: 179675257

7 years agoSpecify that only NHWC is supported for certain ops on CPU specifically, rather than...
Neal Wu [Wed, 20 Dec 2017 03:56:58 +0000 (19:56 -0800)]
Specify that only NHWC is supported for certain ops on CPU specifically, rather than in general.

PiperOrigin-RevId: 179637312

7 years agoElide long strings and lists when summarizing AttrValues.
Peter Hawkins [Wed, 20 Dec 2017 03:22:44 +0000 (19:22 -0800)]
Elide long strings and lists when summarizing AttrValues.

PiperOrigin-RevId: 179635492

7 years agoAdds some more distributed training related fields into TF_CONFIG.
Jianwei Xie [Wed, 20 Dec 2017 03:22:44 +0000 (19:22 -0800)]
Adds some more distributed training related fields into TF_CONFIG.

PiperOrigin-RevId: 179635491

7 years agoSupport ternary ops.
Yao Zhang [Wed, 20 Dec 2017 03:09:00 +0000 (19:09 -0800)]
Support ternary ops.

PiperOrigin-RevId: 179634713

7 years agoUpdate ops-related pbtxt files.
A. Unique TensorFlower [Wed, 20 Dec 2017 03:04:57 +0000 (19:04 -0800)]
Update ops-related pbtxt files.

PiperOrigin-RevId: 179634365

7 years agoGo: Update generated wrapper functions for TensorFlow ops.
A. Unique TensorFlower [Wed, 20 Dec 2017 02:36:51 +0000 (18:36 -0800)]
Go: Update generated wrapper functions for TensorFlow ops.

PiperOrigin-RevId: 179632513

7 years agoMinor cleanup, now that there's a single Executable::ExecuteOnStream method.
A. Unique TensorFlower [Wed, 20 Dec 2017 02:15:52 +0000 (18:15 -0800)]
Minor cleanup, now that there's a single Executable::ExecuteOnStream method.

PiperOrigin-RevId: 179630890

7 years ago[XLA:GPU] Make the use of scratch allocator in convolution_thunk safe.
A. Unique TensorFlower [Wed, 20 Dec 2017 01:54:19 +0000 (17:54 -0800)]
[XLA:GPU] Make the use of scratch allocator in convolution_thunk safe.

Add member function Thunk::ShouldFutureScheduledThunksDependOn for
convolution_thunk to tell thunk executor that all future scheduled thunks
should wait for convolution_thunk. This can ensure that the use of scratch
allocator in convolution_thunk is safe.

PiperOrigin-RevId: 179628764

7 years agoRead ApiDef from TensorFlow Go API.
Anna R [Wed, 20 Dec 2017 01:28:06 +0000 (17:28 -0800)]
Read ApiDef from TensorFlow Go API.

PiperOrigin-RevId: 179625412

7 years ago[tf.data] Add a transformation for getting the unique elements of a dataset.
Derek Murray [Wed, 20 Dec 2017 01:26:02 +0000 (17:26 -0800)]
[tf.data] Add a transformation for getting the unique elements of a dataset.

PiperOrigin-RevId: 179625211

7 years agoImplement convolution operations in the local Python XLA client.
Roy Frostig [Wed, 20 Dec 2017 01:20:17 +0000 (17:20 -0800)]
Implement convolution operations in the local Python XLA client.

PiperOrigin-RevId: 179624737

7 years agotfdbg: send graph traceback and source files from TensorBoard wrapper and hook
Shanqing Cai [Wed, 20 Dec 2017 01:13:50 +0000 (17:13 -0800)]
tfdbg: send graph traceback and source files from TensorBoard wrapper and hook

To this end:
* Refactor some common, shared constants and methods to a new file: common.py

PiperOrigin-RevId: 179624165

7 years agoTFE copy across gpus
Alexandre Passos [Wed, 20 Dec 2017 00:51:25 +0000 (16:51 -0800)]
TFE copy across gpus

PiperOrigin-RevId: 179622259

7 years agoK-FAC: Cross Replica Mean for TPU
A. Unique TensorFlower [Wed, 20 Dec 2017 00:31:31 +0000 (16:31 -0800)]
K-FAC: Cross Replica Mean for TPU

Adds an op for taking the average of a Tensor across all TPU cores, and uses it
before updating covariance statistics. This is a no-op if TPUs aren't used.

PiperOrigin-RevId: 179620193

7 years ago[XLA] Rename CreateFullWithMonotonicDim0MajorLayout to CreateFullWithDescendingLayout.
Justin Lebar [Wed, 20 Dec 2017 00:27:34 +0000 (16:27 -0800)]
[XLA] Rename CreateFullWithMonotonicDim0MajorLayout to CreateFullWithDescendingLayout.

We've renamed MonotonicDim0MajorLayout to DescendingLayout.

PiperOrigin-RevId: 179619563

7 years agoAdd comparison ufuncs for numpy bfloat16 type.
A. Unique TensorFlower [Tue, 19 Dec 2017 23:50:58 +0000 (15:50 -0800)]
Add comparison ufuncs for numpy bfloat16 type.
Fix 2 bfloat16 tests.

PiperOrigin-RevId: 179614898

7 years ago[XLA] Fix return type of LayoutUtil::PaddedDimensions
A. Unique TensorFlower [Tue, 19 Dec 2017 23:45:38 +0000 (15:45 -0800)]
[XLA] Fix return type of LayoutUtil::PaddedDimensions

We should not use const here.

PiperOrigin-RevId: 179614367

7 years agoRemove unused namespace alias.
A. Unique TensorFlower [Tue, 19 Dec 2017 23:26:33 +0000 (15:26 -0800)]
Remove unused namespace alias.

PiperOrigin-RevId: 179612102

7 years agoSupport fused batch norm v2.
Yao Zhang [Tue, 19 Dec 2017 23:07:16 +0000 (15:07 -0800)]
Support fused batch norm v2.

PiperOrigin-RevId: 179609646

7 years ago[XLA] Turn pad and reduce window of zero sized inputs into a broadcast.
Blake Hechtman [Tue, 19 Dec 2017 23:01:53 +0000 (15:01 -0800)]
[XLA] Turn pad and reduce window of zero sized inputs into a broadcast.

PiperOrigin-RevId: 179608875

7 years ago[XLA] Rename "MonotonicDim0MajorLayout" to "DescendingLayout".
Justin Lebar [Tue, 19 Dec 2017 22:56:01 +0000 (14:56 -0800)]
[XLA] Rename "MonotonicDim0MajorLayout" to "DescendingLayout".

This is shorter, and hopefully less confusing.

As a result, we rename NormalizeShapeToMonotonicDim0MajorLayout to the
more descriptive MakeShapeWithDescendingLayoutAndSamePhysicalLayout,
and rename MakeShapewithMonotonicDim0MajorLayout to
MakeShapeWithDescendingLayout.

We also beef up the comments on the first function.

PiperOrigin-RevId: 179608145

7 years agoK-FAC: ResourceVariable support
A. Unique TensorFlower [Tue, 19 Dec 2017 22:21:51 +0000 (14:21 -0800)]
K-FAC: ResourceVariable support

PiperOrigin-RevId: 179603654

7 years agoMigrate SavedModel simple save functionality from contrib to
Sukriti Ramesh [Tue, 19 Dec 2017 21:54:53 +0000 (13:54 -0800)]
Migrate SavedModel simple save functionality from contrib to
tensorflow/python/saved_model.

PiperOrigin-RevId: 179599527

7 years agoFixed a couple of bugs in transitive reduction:
A. Unique TensorFlower [Tue, 19 Dec 2017 21:34:33 +0000 (13:34 -0800)]
Fixed a couple of bugs in transitive reduction:
   1. Only consider paths through nodes reachable from the source in the inner loop.
   2. Ignore paths through Merge nodes, since we cannot know which branch executed.
   3. Ignore function nodes, since we are potentially mixing paths from multiple instantiations.
   4. Process control inputs to be removed in reverse order of input slot, so we don't clobber the repeated field.

PiperOrigin-RevId: 179596846

7 years agoMake sure function.defun can handle nested inputs with namedtuples and dicts.
Sergio Guadarrama [Tue, 19 Dec 2017 21:26:56 +0000 (13:26 -0800)]
Make sure function.defun can handle nested inputs with namedtuples and dicts.

PiperOrigin-RevId: 179595879

7 years agoInitial checkin for outside_compilation. Adds a new attribute for encapsulating XLA...
A. Unique TensorFlower [Tue, 19 Dec 2017 20:54:01 +0000 (12:54 -0800)]
Initial checkin for outside_compilation. Adds a new attribute for encapsulating XLA subgraphs that will in the future be used to mark some Ops in the subgraph as 'outside_compilation' meaning they will be run as interpreted TensorFlow via a callout from a compiled XLA subgraph.

This is the first of a sequence of checkins. It adds new types of edges entering and leaving the subgraphs, suitable for send/recv between a compiled XLA subgraph and the 'host', i.e., uncompiled TensorFlow.

For now no code sets the new 'outside_compilation' attributes, and the Ops to perform the send/recv are not present in the codebase; these will follow in subsequent checkins.

PiperOrigin-RevId: 179591853

7 years agoSupport IdentityN op.
Yao Zhang [Tue, 19 Dec 2017 20:48:55 +0000 (12:48 -0800)]
Support IdentityN op.

PiperOrigin-RevId: 179591229

7 years agoProtect all calls to launch cuSolver & cuBlas kernels by a lock. The code appears...
A. Unique TensorFlower [Tue, 19 Dec 2017 20:38:19 +0000 (12:38 -0800)]
Protect all calls to launch cuSolver & cuBlas kernels by a lock. The code appears not to be threadsafe pre Cuda 9, and we have several report of crashes. Since the overhead is modest, better to be safe.

PiperOrigin-RevId: 179589983

7 years agoSpecifically add TMP directory for Android
Austin Anderson [Tue, 19 Dec 2017 20:16:57 +0000 (12:16 -0800)]
Specifically add TMP directory for Android

There is an oversight in the adb tool that causes `adb shell` ->
$<command> to set the TMPDIR env param, but `adb shell <command>` does
not. Binaries that use env.cc on Android will have inconsistent behavior
between interactive and non-interactive versions of `adb shell` until
that bug (which has been fixed internally) arrives on released versions
of adb.

This change adds the /data/local/tmp directory as a final fallback for
Android devices that support it (/data/local/tmp seems to be the de
facto "anyone can use this" Android tmp directory based on Mobile
Harness's use of it, my own discovery that it works better than other
directories, and that searching for it seems to back up the idea, but I
can't find official documentation supporting this). Devices that don't
support that directory will continue to fail, as they did before.

PiperOrigin-RevId: 179587386

7 years agoSupport for strings input/output in Toco
A. Unique TensorFlower [Tue, 19 Dec 2017 20:09:52 +0000 (12:09 -0800)]
Support for strings input/output in Toco

PiperOrigin-RevId: 179586555

7 years ago[tf.data] Saveable iterator for ScanDataset.
Shivani Agrawal [Tue, 19 Dec 2017 19:47:21 +0000 (11:47 -0800)]
[tf.data] Saveable iterator for ScanDataset.

PiperOrigin-RevId: 179583460

7 years ago[tf.data] Saveable iterator for DenseToSparseBatchDataset.
Shivani Agrawal [Tue, 19 Dec 2017 19:47:16 +0000 (11:47 -0800)]
[tf.data] Saveable iterator for DenseToSparseBatchDataset.

PiperOrigin-RevId: 179583450

7 years agoSupport more binary ops.
Yao Zhang [Tue, 19 Dec 2017 19:46:20 +0000 (11:46 -0800)]
Support more binary ops.

PiperOrigin-RevId: 179583326

7 years agoRemove a series of allocations and memcpys from the GCS read path (TF infeed path).
A. Unique TensorFlower [Tue, 19 Dec 2017 19:33:15 +0000 (11:33 -0800)]
Remove a series of allocations and memcpys from the GCS read path (TF infeed path).

The GCS client uses an intermediate std::vector<char> buffer for all reads. This turns out to have a substantial cost, in allocations and in memcpys. During load testing with a simple tool for measuring GCS throughput (but not running TensorFlow), removing this allocation and memcpy increased throughput by about 8%, and significantly reduced steady-state heap memory used.  I have not measured the impact when running the full TensorFlow pipeline, but I expect there to be gains, due to the lower memory utilization and the lower cache demand.

PiperOrigin-RevId: 179581563

7 years agoFix comment.
Guangda Lai [Tue, 19 Dec 2017 19:14:38 +0000 (11:14 -0800)]
Fix comment.

PiperOrigin-RevId: 179578952

7 years ago[XLA] Add support for atan2 on CPU
A. Unique TensorFlower [Tue, 19 Dec 2017 18:11:58 +0000 (10:11 -0800)]
[XLA] Add support for atan2 on CPU

This leans on the libm's atan2 for the actual routine but allows us to share
the implementation of other complex operations between CPU and GPU.

PiperOrigin-RevId: 179569666

7 years agoAutomated g4 rollback of changelist 179506342
HyoukJoong Lee [Tue, 19 Dec 2017 15:43:14 +0000 (07:43 -0800)]
Automated g4 rollback of changelist 179506342

PiperOrigin-RevId: 179552496

7 years agoRun ResizeArea tests on random data rather than all 0s.
A. Unique TensorFlower [Tue, 19 Dec 2017 15:40:36 +0000 (07:40 -0800)]
Run ResizeArea tests on random data rather than all 0s.

PiperOrigin-RevId: 179552297

7 years agoAutomated g4 rollback of changelist 179529787
Malcolm Reynolds [Tue, 19 Dec 2017 14:36:25 +0000 (06:36 -0800)]
Automated g4 rollback of changelist 179529787

PiperOrigin-RevId: 179546698

7 years agoGo: Update generated wrapper functions for TensorFlow ops.
A. Unique TensorFlower [Tue, 19 Dec 2017 13:48:13 +0000 (05:48 -0800)]
Go: Update generated wrapper functions for TensorFlow ops.

PiperOrigin-RevId: 179542713

7 years agoUpdate ops-related pbtxt files.
A. Unique TensorFlower [Tue, 19 Dec 2017 13:36:22 +0000 (05:36 -0800)]
Update ops-related pbtxt files.

PiperOrigin-RevId: 179542009

7 years agoAvoid casting to/from int64 in Categorical._sample_n
A. Unique TensorFlower [Tue, 19 Dec 2017 10:55:10 +0000 (02:55 -0800)]
Avoid casting to/from int64 in Categorical._sample_n

PiperOrigin-RevId: 179529787

7 years ago[XLA] Adding more tests for conditional.
A. Unique TensorFlower [Tue, 19 Dec 2017 07:07:13 +0000 (23:07 -0800)]
[XLA] Adding more tests for conditional.

PiperOrigin-RevId: 179514274

7 years agoChanged the buffer liveness such that the buffers pointed to by the root
HyoukJoong Lee [Tue, 19 Dec 2017 04:48:26 +0000 (20:48 -0800)]
Changed the buffer liveness such that the buffers pointed to by the root
instruction have liveness to the end of the computation.

PiperOrigin-RevId: 179506342

7 years agoAdded virtual gpu support.
Guangda Lai [Tue, 19 Dec 2017 04:16:08 +0000 (20:16 -0800)]
Added virtual gpu support.

PiperOrigin-RevId: 179504116

7 years ago[XLA] Hlo parser: don't crash if no computation is specified as ENTRY. Also disallow...
A. Unique TensorFlower [Tue, 19 Dec 2017 03:07:23 +0000 (19:07 -0800)]
[XLA] Hlo parser: don't crash if no computation is specified as ENTRY. Also disallow multiple entry computations and multiple root intructions.

PiperOrigin-RevId: 179498839

7 years agoSupport more unary ops.
Yao Zhang [Tue, 19 Dec 2017 02:53:35 +0000 (18:53 -0800)]
Support more unary ops.

PiperOrigin-RevId: 179498141

7 years agoSupport more activation ops.
Yao Zhang [Tue, 19 Dec 2017 01:45:50 +0000 (17:45 -0800)]
Support more activation ops.

PiperOrigin-RevId: 179493169

7 years agoAdd probabilistic convolutional layers.
Dustin Tran [Tue, 19 Dec 2017 01:15:01 +0000 (17:15 -0800)]
Add probabilistic convolutional layers.

PiperOrigin-RevId: 179490700

7 years ago[XLA] Add pow(pow(A, X), Y) => pow(A, X*Y) simplification.
Justin Lebar [Tue, 19 Dec 2017 00:43:08 +0000 (16:43 -0800)]
[XLA] Add pow(pow(A, X), Y) => pow(A, X*Y) simplification.

PiperOrigin-RevId: 179487434

7 years agoFix typo in comment for GetRoot().
A. Unique TensorFlower [Tue, 19 Dec 2017 00:37:40 +0000 (16:37 -0800)]
Fix typo in comment for GetRoot().

PiperOrigin-RevId: 179486882

7 years ago[XLA] Add format field to layout
A. Unique TensorFlower [Mon, 18 Dec 2017 23:14:59 +0000 (15:14 -0800)]
[XLA] Add format field to layout

Format will describe the method used to store array data in memory. Currently
only DENSE is supported, which represents the way XLA currently stores arrays.

Scalars have a DENSE format. Tuples and opaque shapes use INVALID_FORMAT.

Adds checks to code that uses minor_to_major to ensure the layout is dense.

PiperOrigin-RevId: 179475450

7 years agoDelete the instructions regarding manually installing protobuf.
Jonathan Hseu [Mon, 18 Dec 2017 22:01:58 +0000 (14:01 -0800)]
Delete the instructions regarding manually installing protobuf.

PiperOrigin-RevId: 179464468

7 years agoSavedModel tag logging.
Sukriti Ramesh [Mon, 18 Dec 2017 21:20:19 +0000 (13:20 -0800)]
SavedModel tag logging.

PiperOrigin-RevId: 179460064

7 years agoSmall doc fix in kfac loss_functions: `evaluate()` returns *negative* log probabilities.
A. Unique TensorFlower [Mon, 18 Dec 2017 20:42:48 +0000 (12:42 -0800)]
Small doc fix in kfac loss_functions: `evaluate()` returns *negative* log probabilities.

PiperOrigin-RevId: 179456448

7 years ago[XLA:CPU] Parameters and temps for embedded computations are not invariant
Sanjoy Das [Mon, 18 Dec 2017 18:57:22 +0000 (10:57 -0800)]
[XLA:CPU] Parameters and temps for embedded computations are not invariant

PiperOrigin-RevId: 179443961

7 years agoA fast "pow" function for positive integer exponents
A. Unique TensorFlower [Mon, 18 Dec 2017 18:27:34 +0000 (10:27 -0800)]
A fast "pow" function for positive integer exponents

PiperOrigin-RevId: 179439743

7 years ago[XLA] Rename BatchNormRewriter -> BatchNormExpander.
Justin Lebar [Mon, 18 Dec 2017 18:26:35 +0000 (10:26 -0800)]
[XLA] Rename BatchNormRewriter -> BatchNormExpander.

PiperOrigin-RevId: 179439609

7 years agoImplementing a fused version of shuffle and repeat. The logic is incorporated into...
Jiri Simsa [Mon, 18 Dec 2017 17:24:44 +0000 (09:24 -0800)]
Implementing a fused version of shuffle and repeat. The logic is incorporated into the existing `tf.data.Dataset.shuffle_and_repeat` transformation.

Fusing of shuffle and repeat is expected to benefit the performance of pipelines with deep shuffle buffers and/or short epochs as it removes the per epoch initialization of the shuffle buffer.

PiperOrigin-RevId: 179431675

7 years agoPrune unused stateless nodes from function bodies.
Derek Murray [Mon, 18 Dec 2017 17:16:40 +0000 (09:16 -0800)]
Prune unused stateless nodes from function bodies.

Previously, all nodes in a TensorFlow function would be executed
unconditionally, which led to surprising performance issues (such as
executing a expensive image summary op that was created but unused in
a preprocessing function). We can prune nodes that are not
reverse-reachable from the return values of a function if they are
stateless and are not reverse-reachable from a stateful node.

PiperOrigin-RevId: 179430810

7 years agoProvide an option to disable forceinline in cmake build
Gunhan Gulsoy [Mon, 18 Dec 2017 17:11:46 +0000 (09:11 -0800)]
Provide an option to disable forceinline in cmake build

PiperOrigin-RevId: 179430327

7 years agoRe-enable adaptive_shared_batch_scheduler_test after potential bugfix.
Martin Wicke [Mon, 18 Dec 2017 17:04:02 +0000 (09:04 -0800)]
Re-enable adaptive_shared_batch_scheduler_test after potential bugfix.

PiperOrigin-RevId: 179429524

7 years agoFix support for functions to grappler items.
A. Unique TensorFlower [Mon, 18 Dec 2017 17:03:42 +0000 (09:03 -0800)]
Fix support for functions to grappler items.

PiperOrigin-RevId: 179429486

7 years agoRe-enable adaptive_shared_batch_scheduler_test after potential bugfix.
Martin Wicke [Mon, 18 Dec 2017 17:04:02 +0000 (09:04 -0800)]
Re-enable adaptive_shared_batch_scheduler_test after potential bugfix.

PiperOrigin-RevId: 179429524

7 years agoFix support for functions to grappler items.
A. Unique TensorFlower [Mon, 18 Dec 2017 17:03:42 +0000 (09:03 -0800)]
Fix support for functions to grappler items.

PiperOrigin-RevId: 179429486

7 years agoThis is a bug fix for multi-replica training. When there is any parameter servers...
A. Unique TensorFlower [Mon, 18 Dec 2017 15:42:47 +0000 (07:42 -0800)]
This is a bug fix for multi-replica training. When there is any parameter servers and more than one replica, replicas except the chief replica would complain un-initialized stale_counter variable since it doesn't live in parameter server.

PiperOrigin-RevId: 179421368

7 years agoSync Premade and Custom estimator docs with example code.
Mark Daoust [Mon, 18 Dec 2017 12:12:29 +0000 (04:12 -0800)]
Sync Premade and Custom estimator docs with example code.

PiperOrigin-RevId: 179404175

7 years agoUpdate readme.
A. Unique TensorFlower [Mon, 18 Dec 2017 06:38:49 +0000 (22:38 -0800)]
Update readme.

PiperOrigin-RevId: 179380041

7 years ago[XLA] Don't reimplement ShapeUtil::MakeShapeWithMonotonicDim0MajorLayout inside of...
Justin Lebar [Mon, 18 Dec 2017 05:10:28 +0000 (21:10 -0800)]
[XLA] Don't reimplement ShapeUtil::MakeShapeWithMonotonicDim0MajorLayout inside of layout_assignment.

No functional change.

PiperOrigin-RevId: 179376105

7 years ago[XLA] Fix comments on HloInstruction::epsilon() and HloInstruction::feature_index().
Justin Lebar [Mon, 18 Dec 2017 00:02:29 +0000 (16:02 -0800)]
[XLA] Fix comments on HloInstruction::epsilon() and HloInstruction::feature_index().

These functions can be called for kBatchNorm{Training,Inference,Grad},
not just kBatchNormTraining.

No functional change.

PiperOrigin-RevId: 179363059

7 years agoauto_correlation added to tf.contrib.distributions
Ian Langmore [Sun, 17 Dec 2017 22:16:48 +0000 (14:16 -0800)]
auto_correlation added to tf.contrib.distributions

PiperOrigin-RevId: 179359575

7 years ago[StreamExecutor] Change "variance" to "inv_var" in BatchNormalizationBackward.
Justin Lebar [Sun, 17 Dec 2017 18:43:11 +0000 (10:43 -0800)]
[StreamExecutor] Change "variance" to "inv_var" in BatchNormalizationBackward.

This parameter is not the variance of the data, but rather is
1/(sqrt(variance + epsilon).  Neglecting epsilon, this is the inverse
standard deviation.

"inv_stddev" might be a better name, but "inv_var" is certainly better
than plain "variance", and it matches nvidia's name for this parameter,
which I think may override the desire for a more precise name.

No functional change.

PiperOrigin-RevId: 179352839

7 years ago[StreamExecutor] Allow null batch_mean/batch_var in calls to BatchNormalizationForward.
Justin Lebar [Sun, 17 Dec 2017 17:43:37 +0000 (09:43 -0800)]
[StreamExecutor] Allow null batch_mean/batch_var in calls to BatchNormalizationForward.

cudnn allows these pointers to be null, so we should too.  This lets us
avoid an unnecessary ThenMemZero, and lets callers avoid an unnecessary
allocation.

PiperOrigin-RevId: 179350594

7 years ago[XLA] Fix bugs and improve error messages in tuple comparisons in literal_test_util.
Justin Lebar [Sun, 17 Dec 2017 16:37:31 +0000 (08:37 -0800)]
[XLA] Fix bugs and improve error messages in tuple comparisons in literal_test_util.

 * Fix bug where EqualsTuple() only compared the first tuple element (!).
 * Compare all tuple elements, even when the first one fails.
 * Print out which tuple element we're looking at when we get a
   mismatch.

PiperOrigin-RevId: 179348614

7 years ago[XLA] Shorten "custom_call_target" to "target" in XLA graph dumper.
Justin Lebar [Sun, 17 Dec 2017 15:54:51 +0000 (07:54 -0800)]
[XLA] Shorten "custom_call_target" to "target" in XLA graph dumper.

Make CustomCall nodes a bit smaller by shortening
"custom_call_target=" to "target=".

PiperOrigin-RevId: 179347188

7 years agoGo: Update generated wrapper functions for TensorFlow ops.
A. Unique TensorFlower [Sun, 17 Dec 2017 10:26:46 +0000 (02:26 -0800)]
Go: Update generated wrapper functions for TensorFlow ops.

PiperOrigin-RevId: 179335476

7 years agoUpdate ops-related pbtxt files.
A. Unique TensorFlower [Sun, 17 Dec 2017 10:16:16 +0000 (02:16 -0800)]
Update ops-related pbtxt files.

PiperOrigin-RevId: 179335105

7 years agoIntroduce the ContinuousEvalListener
Jianwei Xie [Sun, 17 Dec 2017 02:57:31 +0000 (18:57 -0800)]
Introduce the ContinuousEvalListener

PiperOrigin-RevId: 179319836

7 years agoCreate the contrib directory for the Eager to graph compiler.
A. Unique TensorFlower [Sun, 17 Dec 2017 00:23:27 +0000 (16:23 -0800)]
Create the contrib directory for the Eager to graph compiler.

PiperOrigin-RevId: 179314481

7 years agoAdd DenseFlipout probabilistic layer.
Dustin Tran [Sat, 16 Dec 2017 22:29:08 +0000 (14:29 -0800)]
Add DenseFlipout probabilistic layer.

PiperOrigin-RevId: 179310861

7 years agoSupport non-const paddings.
Yao Zhang [Sat, 16 Dec 2017 22:21:18 +0000 (14:21 -0800)]
Support non-const paddings.

PiperOrigin-RevId: 179310587

7 years agonit: it's --> its
A. Unique TensorFlower [Sat, 16 Dec 2017 22:03:34 +0000 (14:03 -0800)]
nit: it's --> its

PiperOrigin-RevId: 179309732

7 years agoFirst and second dimension should be reversed.
Yao Zhang [Sat, 16 Dec 2017 21:21:31 +0000 (13:21 -0800)]
First and second dimension should be reversed.

PiperOrigin-RevId: 179308396

7 years agoUpdating sparsify gather to work with core estimators.
A. Unique TensorFlower [Sat, 16 Dec 2017 20:24:36 +0000 (12:24 -0800)]
Updating sparsify gather to work with core estimators.

PiperOrigin-RevId: 179306398

7 years agoRemoves the TpuContext from non-TPU mode.
Jianwei Xie [Sat, 16 Dec 2017 18:09:18 +0000 (10:09 -0800)]
Removes the TpuContext from non-TPU mode.

PiperOrigin-RevId: 179302096

7 years agoGo: Update generated wrapper functions for TensorFlow ops.
A. Unique TensorFlower [Sat, 16 Dec 2017 14:11:24 +0000 (06:11 -0800)]
Go: Update generated wrapper functions for TensorFlow ops.

PiperOrigin-RevId: 179294028

7 years agoUpdate ops-related pbtxt files.
A. Unique TensorFlower [Sat, 16 Dec 2017 13:54:26 +0000 (05:54 -0800)]
Update ops-related pbtxt files.

PiperOrigin-RevId: 179293176

7 years agoMerged commit includes the following changes:
A. Unique TensorFlower [Sat, 16 Dec 2017 07:38:01 +0000 (23:38 -0800)]
Merged commit includes the following changes:
179277894  by gunan:

    Run buildifier on build file.

--
179275101  by meheff:

    Replace DeviceMemoryBase with ShapedBuffer in XLA interfaces.
    Executable, TransferManager, and AllocationTracker now use ShapedBuffer to hold device memory addresses holding XLA data. Most of the change is straight-forward with the exception of AllocationTracker which was mostly rewritten (and simplified) and some refactoring in the CPU executable.

    Also, have ShapedBuffer hold on-host and on-device Shapes which are the shapes of the representation of the data on the host and device, respectively. This is necessary because with cl/178624364 the on-host and on-device shape may no longer be equal.

--
179265385  by A. Unique TensorFlower:

    Return error rather than CHECK fail in Executable::ExecuteOnStreamWrapper

--
179264551  by dandelion:

    Internal fixes.

--

PiperOrigin-RevId: 179277894

7 years ago[tf.contrib.rnn] Fix regression in variable creation in fused LSTM/GRU cells.
Eugene Brevdo [Sat, 16 Dec 2017 02:22:15 +0000 (18:22 -0800)]
[tf.contrib.rnn] Fix regression in variable creation in fused LSTM/GRU cells.

PiperOrigin-RevId: 179264398

7 years ago [tpu:profiler] Remove unused fields in ProfileResponse.
A. Unique TensorFlower [Sat, 16 Dec 2017 02:22:06 +0000 (18:22 -0800)]
   [tpu:profiler] Remove unused fields in ProfileResponse.

PiperOrigin-RevId: 179264385

7 years agoAutomated g4 rollback of changelist 179260538
Dandelion Man? [Sat, 16 Dec 2017 02:15:07 +0000 (18:15 -0800)]
Automated g4 rollback of changelist 179260538

PiperOrigin-RevId: 179263865

7 years ago[XLA] Support Map in HloEvaluator, enable Interpreter to run
Kay Zhu [Sat, 16 Dec 2017 02:11:47 +0000 (18:11 -0800)]
[XLA] Support Map in HloEvaluator, enable Interpreter to run
xla/tests:map_map_test which tests this change.

Additionally:
- templatize Evaluate* methods to specialize on both std::unique_ptr<Literal> and const Literal* type of input literal arguments.
- add ResetVisitState to DfsHloVisitor such that a visitor instance can traverse the same HLO graph more than once.
PiperOrigin-RevId: 179263540

7 years agoAutomated g4 rollback of changelist 179258973
A. Unique TensorFlower [Sat, 16 Dec 2017 01:32:50 +0000 (17:32 -0800)]
Automated g4 rollback of changelist 179258973

PiperOrigin-RevId: 179260538

7 years agoPrint both number of nodes and edges after each Grappler optimizer.
A. Unique TensorFlower [Sat, 16 Dec 2017 01:31:22 +0000 (17:31 -0800)]
Print both number of nodes and edges after each Grappler optimizer.

PiperOrigin-RevId: 179260418

7 years agoMerge changes from github.
Dandelion Man? [Sat, 16 Dec 2017 01:12:41 +0000 (17:12 -0800)]
Merge changes from github.

PiperOrigin-RevId: 179258973