platform/upstream/tensorflow.git
6 years agoAvoid mixing `Dimension` type and `int` when defining kernel shapes in conv layers.
Francois Chollet [Fri, 13 Apr 2018 22:33:07 +0000 (15:33 -0700)]
Avoid mixing `Dimension` type and `int` when defining kernel shapes in conv layers.

PiperOrigin-RevId: 192834255

6 years ago[XLA] Pattern matcher for HLO, Shapes, Layouts
A. Unique TensorFlower [Fri, 13 Apr 2018 22:32:11 +0000 (15:32 -0700)]
[XLA] Pattern matcher for HLO, Shapes, Layouts

PiperOrigin-RevId: 192834129

6 years agoAdd broadcasting to all LinearOperators.
A. Unique TensorFlower [Fri, 13 Apr 2018 22:23:08 +0000 (15:23 -0700)]
Add broadcasting to all LinearOperators.

This will broadcast in cases where batch shapes are not equal (but tries to determine statically if this is the case). The broadcasting is not as efficient as doing the broadcast in C++, but makes for the API to at least be completely broadcastable.

PiperOrigin-RevId: 192832919

6 years ago[TF] Enable half precision XLA compiler tests for the gpu backend.
Bixia Zheng [Fri, 13 Apr 2018 22:15:44 +0000 (15:15 -0700)]
[TF] Enable half precision XLA compiler tests for the gpu backend.

Modify some tests to allow larger error for half precision.

Enable half precision SpaceToBatchNDTest for the cpu backend.

PiperOrigin-RevId: 192831909

6 years agoAdded PmfToQuantizedCdf op to contrib/coder in TensorFlow.
Sung Jin Hwang [Fri, 13 Apr 2018 21:51:16 +0000 (14:51 -0700)]
Added PmfToQuantizedCdf op to contrib/coder in TensorFlow.

The added op transforms probability mass functions (PMF) to quantized
cumulative distribution function (CDF), which can be used by range coder ops in
contrib/coder.

The op takes greedy approach to ensure that the post-quantization probability
masses do not sum over the maximum quantized value. The op does not make any
adjustment when the post-quantization probability masses already sum less than
the maximum value.

PiperOrigin-RevId: 192827779

6 years agoAllow tf.train.Saver to load object-based checkpoints (using names)
Allen Lavoie [Fri, 13 Apr 2018 21:32:45 +0000 (14:32 -0700)]
Allow tf.train.Saver to load object-based checkpoints (using names)

This is the second part of the compatibility story. Object-based checkpointing APIs can already read name-based checkpoints, and now the name-based APIs can read object-based checkpoints by looking up the modified keys in the object graph proto.

PiperOrigin-RevId: 192824907

6 years ago[XLA] Redesign: add ~XlaOp() and ~XlaComputation().
A. Unique TensorFlower [Fri, 13 Apr 2018 21:17:31 +0000 (14:17 -0700)]
[XLA] Redesign: add ~XlaOp() and ~XlaComputation().

PiperOrigin-RevId: 192822559

6 years agoSmall tag change
Austin Anderson [Fri, 13 Apr 2018 21:13:12 +0000 (14:13 -0700)]
Small tag change

PiperOrigin-RevId: 192821895

6 years agoExtend Keras symbol-feeding to dynamic-length tensors and tensors of different dtypes...
Francois Chollet [Fri, 13 Apr 2018 21:12:16 +0000 (14:12 -0700)]
Extend Keras symbol-feeding to dynamic-length tensors and tensors of different dtypes from the target placeholders.

PiperOrigin-RevId: 192821770

6 years agoInternal change.
Anna R [Fri, 13 Apr 2018 21:09:58 +0000 (14:09 -0700)]
Internal change.

PiperOrigin-RevId: 192821482

6 years agoSupport scalar mean in resolve_batch_normalization
A. Unique TensorFlower [Fri, 13 Apr 2018 20:40:28 +0000 (13:40 -0700)]
Support scalar mean in resolve_batch_normalization

PiperOrigin-RevId: 192816848

6 years agoRemove closure_js_proto_library rule for tf.example protos.
James Wexler [Fri, 13 Apr 2018 19:44:41 +0000 (12:44 -0700)]
Remove closure_js_proto_library rule for tf.example protos.

PiperOrigin-RevId: 192809073

6 years ago[XLA] Redesign: add a constructor: XlaComputation(HloModuleProto).
A. Unique TensorFlower [Fri, 13 Apr 2018 19:37:04 +0000 (12:37 -0700)]
[XLA] Redesign: add a constructor: XlaComputation(HloModuleProto).

PiperOrigin-RevId: 192808038

6 years ago[XLA] Redesign: add a method that creates fake data for XlaComputation.
A. Unique TensorFlower [Fri, 13 Apr 2018 19:35:32 +0000 (12:35 -0700)]
[XLA] Redesign: add a method that creates fake data for XlaComputation.

PiperOrigin-RevId: 192807851

6 years agoExpose tf.decode_compressed to the public API.
A. Unique TensorFlower [Fri, 13 Apr 2018 19:18:53 +0000 (12:18 -0700)]
Expose tf.decode_compressed to the public API.

PiperOrigin-RevId: 192805605

6 years agoFixing output alternatives
A. Unique TensorFlower [Fri, 13 Apr 2018 18:16:36 +0000 (11:16 -0700)]
Fixing output alternatives

PiperOrigin-RevId: 192795596

6 years ago[TF:XLA] Start a TensorFlow library that contains direct wrappers for XLA operators.
Peter Hawkins [Fri, 13 Apr 2018 18:14:09 +0000 (11:14 -0700)]
[TF:XLA] Start a TensorFlow library that contains direct wrappers for XLA operators.

Add new XlaReduceWindow and XlaDynamicUpdateSlice operators.
Add new tests for the existing XlaWhile operator.
Add wrappers for XlaSend and XlaRecv.

PiperOrigin-RevId: 192795174

6 years agoAdd more logging for failure cases in CUDATimer
James Qin [Fri, 13 Apr 2018 18:06:49 +0000 (11:06 -0700)]
Add more logging for failure cases in CUDATimer

PiperOrigin-RevId: 192793983

6 years agoFix comment in xla_data.proto related to padding value for Windows.
Mark Heffernan [Fri, 13 Apr 2018 18:02:08 +0000 (11:02 -0700)]
Fix comment in xla_data.proto related to padding value for Windows.

PiperOrigin-RevId: 192792971

6 years agoInternal change.
Anna R [Fri, 13 Apr 2018 17:52:56 +0000 (10:52 -0700)]
Internal change.

PiperOrigin-RevId: 192791493

6 years agoDisable x * x -> square(x) Grapler rewrite for complex types unless the op is on...
A. Unique TensorFlower [Fri, 13 Apr 2018 17:30:32 +0000 (10:30 -0700)]
Disable x * x -> square(x) Grapler rewrite for complex types unless the op is on CPU. Square is not registered for complex types on GPU, and doing so produces a crash in with CUDA_ILLEGAL_INSTRUCTION when running it on open source ubuntu.

PiperOrigin-RevId: 192788160

6 years agoDepthwiseConv Optimization Fixes
A. Unique TensorFlower [Fri, 13 Apr 2018 17:27:11 +0000 (10:27 -0700)]
DepthwiseConv Optimization Fixes

PiperOrigin-RevId: 192787669

6 years agoEnable GCS remote cache in Windows Bazel Build
A. Unique TensorFlower [Fri, 13 Apr 2018 17:07:10 +0000 (10:07 -0700)]
Enable GCS remote cache in Windows Bazel Build

PiperOrigin-RevId: 192784701

6 years agoAdd debugging checks for setting cuda stream, so it will check fail if the
Guangda Lai [Fri, 13 Apr 2018 17:02:25 +0000 (10:02 -0700)]
Add debugging checks for setting cuda stream, so it will check fail if the
stream is not set or set to a wrong one when running cudnn methods that
conceptually require a stream.

Also add missing cudnnSetStream()s for DoRnnForwardImpl() and
DoRnnBackwardImpl().

Implementation details:
1. a current_cudnn_stream_ member is added which will be set in cudnnSetStream()
2. a different macro is used to wrap cudnn methods that require a stream in
   order to verify whether the provided stream is same as current_cudnn_stream_,
   and the program will check fail if not

PiperOrigin-RevId: 192783913

6 years agoExperiment with pre-shuffled fully-connected weights
A. Unique TensorFlower [Fri, 13 Apr 2018 15:22:06 +0000 (08:22 -0700)]
Experiment with pre-shuffled fully-connected weights

PiperOrigin-RevId: 192771889

6 years agoRefactor to remove the duplicate calls to obtain a function's namespace. This removes...
A. Unique TensorFlower [Fri, 13 Apr 2018 15:17:49 +0000 (08:17 -0700)]
Refactor to remove the duplicate calls to obtain a function's namespace. This removes the need to explicitly import internal components (barring the tf module which cannot be imported directly).

PiperOrigin-RevId: 192771440

6 years agoAdd support to TFLite for dilated convolution.
A. Unique TensorFlower [Fri, 13 Apr 2018 15:12:42 +0000 (08:12 -0700)]
Add support to TFLite for dilated convolution.

PiperOrigin-RevId: 192770919

6 years agoAutomated g4 rollback of changelist 192768744
A. Unique TensorFlower [Fri, 13 Apr 2018 15:10:57 +0000 (08:10 -0700)]
Automated g4 rollback of changelist 192768744

PiperOrigin-RevId: 192770717

6 years agoSplit byte_order.h off cpu_info.h
A. Unique TensorFlower [Fri, 13 Apr 2018 14:55:46 +0000 (07:55 -0700)]
Split byte_order.h off cpu_info.h

PiperOrigin-RevId: 192768744

6 years agoDemo: RNN colorbot with Estimators.
A. Unique TensorFlower [Fri, 13 Apr 2018 14:24:15 +0000 (07:24 -0700)]
Demo: RNN colorbot with Estimators.

PiperOrigin-RevId: 192765203

6 years agoKeep function doc string at the top of the function.
A. Unique TensorFlower [Fri, 13 Apr 2018 13:53:54 +0000 (06:53 -0700)]
Keep function doc string at the top of the function.

PiperOrigin-RevId: 192761604

6 years ago- Fixed small bug in example script
A. Unique TensorFlower [Fri, 13 Apr 2018 12:47:21 +0000 (05:47 -0700)]
- Fixed small bug in example script

PiperOrigin-RevId: 192756152

6 years agoUpdate for upstream LLVM *.def -> *.inc rename
A. Unique TensorFlower [Fri, 13 Apr 2018 12:05:12 +0000 (05:05 -0700)]
Update for upstream LLVM *.def -> *.inc rename

PiperOrigin-RevId: 192752798

6 years agoFix bug in converted_call, and add tests for it.
A. Unique TensorFlower [Fri, 13 Apr 2018 11:44:10 +0000 (04:44 -0700)]
Fix bug in converted_call, and add tests for it.

PiperOrigin-RevId: 192751211

6 years agoImplementation of Less
A. Unique TensorFlower [Fri, 13 Apr 2018 07:12:41 +0000 (00:12 -0700)]
Implementation of Less

PiperOrigin-RevId: 192728635

6 years ago-- Add a new histogram/cdf computation method compatible with the TPU.
A. Unique TensorFlower [Fri, 13 Apr 2018 07:03:48 +0000 (00:03 -0700)]
-- Add a new histogram/cdf computation method compatible with the TPU.
-- Refactor utility functions into pruning_utils.py and add tests

PiperOrigin-RevId: 192727737

6 years ago[XLA] Rename Interpreter{Executor,Platform} -> XlaInterpreter{Executor,Platform}.
Justin Lebar [Fri, 13 Apr 2018 06:05:35 +0000 (23:05 -0700)]
[XLA] Rename Interpreter{Executor,Platform} -> XlaInterpreter{Executor,Platform}.

These types live inside StreamExecutor's namespace, but they are
specific to XLA.  Therefore they either shouldn't live in SE's namespace
or should have "XLA" in the name.

Moving them out of SE's namespace is ugly, because almost every type
used inside of these headers then needs to be qualified.  So name-change
it is.

This patch was generated by a mechanical find/replace.

PiperOrigin-RevId: 192724238

6 years agoAutomated g4 rollback of changelist 192698931
Jiri Simsa [Fri, 13 Apr 2018 04:39:26 +0000 (21:39 -0700)]
Automated g4 rollback of changelist 192698931

PiperOrigin-RevId: 192718697

6 years agoAutomated g4 rollback of changelist 192504411
Jiri Simsa [Fri, 13 Apr 2018 02:56:38 +0000 (19:56 -0700)]
Automated g4 rollback of changelist 192504411

PiperOrigin-RevId: 192711501

6 years agoAdd boolean type to tflite in favor of comparison implementations.
A. Unique TensorFlower [Fri, 13 Apr 2018 02:52:18 +0000 (19:52 -0700)]
Add boolean type to tflite in favor of comparison implementations.

PiperOrigin-RevId: 192711203

6 years agoAutomated g4 rollback of changelist 192691078
Jiri Simsa [Fri, 13 Apr 2018 02:13:18 +0000 (19:13 -0700)]
Automated g4 rollback of changelist 192691078

PiperOrigin-RevId: 192708480

6 years agoEnable efficient feeding of symbolic tensors to placeholders in the Keras backend.
Francois Chollet [Fri, 13 Apr 2018 02:01:10 +0000 (19:01 -0700)]
Enable efficient feeding of symbolic tensors to placeholders in the Keras backend.

PiperOrigin-RevId: 192707345

6 years agoAvoid calling K.learning_phase() when not necessary in Dropout layer since it instant...
Francois Chollet [Fri, 13 Apr 2018 01:36:13 +0000 (18:36 -0700)]
Avoid calling K.learning_phase() when not necessary in Dropout layer since it instantiates a placeholder_with_default, which is not supported by TPU compilation.

PiperOrigin-RevId: 192705478

6 years agoConvert GrapplerFunctionItem to (Specialized)FunctionDef.
A. Unique TensorFlower [Fri, 13 Apr 2018 01:29:05 +0000 (18:29 -0700)]
Convert GrapplerFunctionItem to (Specialized)FunctionDef.

PiperOrigin-RevId: 192704808

6 years agoAdding autograph built-in function checker.
A. Unique TensorFlower [Fri, 13 Apr 2018 01:19:05 +0000 (18:19 -0700)]
Adding autograph built-in function checker.

PiperOrigin-RevId: 192703924

6 years agoReintroducing support for constants as outputs of tf.data.map(). This fixes a regress...
Jiri Simsa [Fri, 13 Apr 2018 01:02:58 +0000 (18:02 -0700)]
Reintroducing support for constants as outputs of tf.data.map(). This fixes a regression introduced by cl/176147440.

PiperOrigin-RevId: 192702279

6 years agoPrint error msg in CUDATimer.Init() when CreateEvent() is not ok().
James Qin [Fri, 13 Apr 2018 00:35:56 +0000 (17:35 -0700)]
Print error msg in CUDATimer.Init() when CreateEvent() is not ok().

PiperOrigin-RevId: 192699277

6 years agoPorting tests for `rpc_op` to OS.
Jiri Simsa [Fri, 13 Apr 2018 00:32:36 +0000 (17:32 -0700)]
Porting tests for `rpc_op` to OS.

PiperOrigin-RevId: 192698931

6 years agoMove dummy AssertOp and CheckNumericsOp to //third_party/tensorflow/compiler/tf2xla...
A. Unique TensorFlower [Fri, 13 Apr 2018 00:07:35 +0000 (17:07 -0700)]
Move dummy AssertOp and CheckNumericsOp to //third_party/tensorflow/compiler/tf2xla/kernels.
Enable type DT_STRING for AssertOp and ConstOp, in order to make dummy Assert compile with a const string (assert message) as its input.

PiperOrigin-RevId: 192695938

6 years agoFix a typo in cross_tower_ops.
Yuefeng Zhou [Fri, 13 Apr 2018 00:01:55 +0000 (17:01 -0700)]
Fix a typo in cross_tower_ops.

PiperOrigin-RevId: 192694794

6 years agoMisc. small optimizations in Grappler and shape inference code.
A. Unique TensorFlower [Thu, 12 Apr 2018 23:59:57 +0000 (16:59 -0700)]
Misc. small optimizations in Grappler and shape inference code.

Impact on time per optimizer on inception graph:

model_pruner:          590 ms -> 550 ms   (-7%)
function_optimizer:    130 ms -> 130 ms   (-0%)
constant_folding:     7600 ms -> 7550 ms  (-0.7%)
arithmetic_optimizer: 1860 ms -> 1550 ms  (-20%)
loop_optimizer:        320 ms -> 320 ms   (-0%)
dependency_optimizer: 1300 ms -> 720 ms   (-45%)
layout:               1400 ms -> 1400 ms  (-0%)
memory_optimizer:     4200 ms -> 3540 ms  (-16%)
PiperOrigin-RevId: 192694528

6 years agoDocument support for boolean values in tf.contrib.training.HParams.
Stephan Hoyer [Thu, 12 Apr 2018 23:57:40 +0000 (16:57 -0700)]
Document support for boolean values in tf.contrib.training.HParams.

PiperOrigin-RevId: 192694244

6 years ago[XLA:GPU] Pass all four args to custom-call convs when they're created.
Justin Lebar [Thu, 12 Apr 2018 23:56:45 +0000 (16:56 -0700)]
[XLA:GPU] Pass all four args to custom-call convs when they're created.

A custom-call-conv should have four arguments: lhs, rhs, algorithm, and
use-tensor-cores.  CudnnAlgorithmPicker did the right thing, and that
path is exercised 99% of the time.  But CudnnAlgorithmPicker can fail,
and if it does, we're stuck with whatever we had before.  What we had
before only had three of the four args, which is bad.

In addition to fixing it, added an e2e test that catches the bug.

PiperOrigin-RevId: 192694119

6 years agoPropagate sharding of the source instruction to the copies added by layout assignment.
A. Unique TensorFlower [Thu, 12 Apr 2018 23:55:30 +0000 (16:55 -0700)]
Propagate sharding of the source instruction to the copies added by layout assignment.

PiperOrigin-RevId: 192693972

6 years agoChange assertions to use the tensor 'x' rather than 'x.op.name'. This enables eager...
A. Unique TensorFlower [Thu, 12 Apr 2018 23:51:43 +0000 (16:51 -0700)]
Change assertions to use the tensor 'x' rather than 'x.op.name'. This enables eager execution in validate_args=True contexts.

PiperOrigin-RevId: 192693458

6 years agoExposing tensorflow.contrib.proto in the pip package.
Jiri Simsa [Thu, 12 Apr 2018 23:35:47 +0000 (16:35 -0700)]
Exposing tensorflow.contrib.proto in the pip package.

PiperOrigin-RevId: 192691078

6 years agoAdd support for RNN state array of type tf.identity.
A. Unique TensorFlower [Thu, 12 Apr 2018 23:26:13 +0000 (16:26 -0700)]
Add support for RNN state array of type tf.identity.

PiperOrigin-RevId: 192689747

6 years agoAdded a utility to compute a topo ordering of a graph
Benoit Steiner [Thu, 12 Apr 2018 22:41:41 +0000 (15:41 -0700)]
Added a utility to compute a topo ordering of a graph

PiperOrigin-RevId: 192683166

6 years ago[tf.data] Clean up //tensorflow/contrib/data/python/ops/BUILD.
Derek Murray [Thu, 12 Apr 2018 22:20:34 +0000 (15:20 -0700)]
[tf.data] Clean up //tensorflow/contrib/data/python/ops/BUILD.

Create spearate targets for each submodule, so that each test can depend on
the appropriate subset of Python files.

PiperOrigin-RevId: 192679856

6 years agoCheck if the session has been deleted before releasing a callable.
Derek Murray [Thu, 12 Apr 2018 22:20:18 +0000 (15:20 -0700)]
Check if the session has been deleted before releasing a callable.

In some versions of Python, the Session._session field may be cleared
(in `Session.__del__()`) before a callable that has a reference to
that Session is deleted. Add a defensive check in the
`Session._Callable.__del__()` method.

PiperOrigin-RevId: 192679796

6 years agoK-FAC: Deprecate tf.contrib.kfac.
A. Unique TensorFlower [Thu, 12 Apr 2018 21:33:16 +0000 (14:33 -0700)]
K-FAC: Deprecate tf.contrib.kfac.

As LayerCollections are required to instantiate KfacOptimizer and FisherEstimator, a deprecation warning is printed upon instantiating LayerCollection.

PiperOrigin-RevId: 192671370

6 years agoResolveConstantReshape transformation and fix for ResolveConstantTranspose.
A. Unique TensorFlower [Thu, 12 Apr 2018 21:31:08 +0000 (14:31 -0700)]
ResolveConstantReshape transformation and fix for ResolveConstantTranspose.

PiperOrigin-RevId: 192670991

6 years agoMake new build target public.
James Wexler [Thu, 12 Apr 2018 20:24:51 +0000 (13:24 -0700)]
Make new build target public.

PiperOrigin-RevId: 192659759

6 years agoFix build breakage on metagraph exporting when caching_device is set
Alexandre Passos [Thu, 12 Apr 2018 20:24:32 +0000 (13:24 -0700)]
Fix build breakage on metagraph exporting when caching_device is set

PiperOrigin-RevId: 192659701

6 years agoSeparate out distribute dependency out of training, as it needs to be used in summary...
Priya Gupta [Thu, 12 Apr 2018 20:06:28 +0000 (13:06 -0700)]
Separate out distribute dependency out of training, as it needs to be used in summary utils (which training depends on, thus causing circular dependency).

PiperOrigin-RevId: 192656997

6 years agoUpgrade libjpeg-turbo
Justine Tunney [Thu, 12 Apr 2018 19:58:05 +0000 (12:58 -0700)]
Upgrade libjpeg-turbo

NOTE: libjpeg-turbo 1.5.90 also exists, which adds AVX2 SIMD support. However
it also comes with a CMake build rewrite and 35 micro-architecture specialized
nasm files for x86_64 alone. We do not have the cycles to update jpeg.BUILD to
incorporate those changes at this time. If anyone wants to try, please note
we'd need predicates such as the following:

config_setting(
    name = "haswell_opt",
    values = {
        "cpu": "haswell",  # First Intel chip with AVX2
        "compilation_mode": "opt",
    },
    visibility = ["//visibility:public"],
)

config_setting(
    name = "excavator_opt",
    values = {
        "cpu": "excavator",  # First AMD chip with AVX2
        "compilation_mode": "opt",
    },
    visibility = ["//visibility:public"],
)

PiperOrigin-RevId: 192655533

6 years agoFix comment of bucket_by_sequence_length about return type of
A. Unique TensorFlower [Thu, 12 Apr 2018 19:39:48 +0000 (12:39 -0700)]
Fix comment of bucket_by_sequence_length about return type of
element_length_func. Current code requires tf.int32 in order to compare with
buckets_min which is int32.

PiperOrigin-RevId: 192652917

6 years agoRestore dependency on estimator utils from model.
A. Unique TensorFlower [Thu, 12 Apr 2018 19:29:48 +0000 (12:29 -0700)]
Restore dependency on estimator utils from model.

PiperOrigin-RevId: 192651583

6 years ago[XLA] Redesign: add XlaComputation::IsNull.
A. Unique TensorFlower [Thu, 12 Apr 2018 19:12:16 +0000 (12:12 -0700)]
[XLA] Redesign: add XlaComputation::IsNull.

PiperOrigin-RevId: 192649052

6 years agoAdd softsign bijector.
A. Unique TensorFlower [Thu, 12 Apr 2018 19:09:43 +0000 (12:09 -0700)]
Add softsign bijector.

PiperOrigin-RevId: 192648596

6 years agoAdd FunctionTest.testLayerInDefun
Igor Ganichev [Thu, 12 Apr 2018 19:04:48 +0000 (12:04 -0700)]
Add FunctionTest.testLayerInDefun

PiperOrigin-RevId: 192647818

6 years agoStart moving Checkpointable utilities toward core
Allen Lavoie [Thu, 12 Apr 2018 18:59:08 +0000 (11:59 -0700)]
Start moving Checkpointable utilities toward core

Doesn't add to the public API yet, just shifts code around. Changes:
  - A tiny bit of renaming (to avoid having _Checkpoint and Checkpoint in the same file)
  - Removed the garbage collection decorator from a few tests due to the uuid4() garbage issue (apparently core tests get run on Python 2.7.9?)
  - Renamed "Object" to "CheckpointableObject" in the proto, since core protos have Java bindings and apparently Java had something else in mind for the keyword "Object" :)
but otherwise this is a pure move.

After this CL I'll propose adding tf.train.Checkpoint to the API (currently tf.contrib.eager.Checkpoint), move the utilities that are still in contrib/eager to their own contrib directory (there will be a few more misc. utilities for inspecting checkpoints and managing dependencies), get tf.train.Saver to read object-based checkpoints for compatibility, and work on Model.save_weights/load_weights.

PiperOrigin-RevId: 192646890

6 years agoAdd testCompileTimeConstantsInDefun in xla
Igor Ganichev [Thu, 12 Apr 2018 18:54:21 +0000 (11:54 -0700)]
Add testCompileTimeConstantsInDefun in xla

PiperOrigin-RevId: 192646199

6 years agoConstruct Orthogonal kernels for 2d convolutions.
A. Unique TensorFlower [Thu, 12 Apr 2018 18:51:34 +0000 (11:51 -0700)]
Construct Orthogonal kernels for 2d convolutions.

PiperOrigin-RevId: 192645769

6 years agoGo: Update generated wrapper functions for TensorFlow ops.
A. Unique TensorFlower [Thu, 12 Apr 2018 18:46:26 +0000 (11:46 -0700)]
Go: Update generated wrapper functions for TensorFlow ops.
PiperOrigin-RevId: 192644946

6 years agoFixed error where no background audio samples were being used when testing no-speech...
Pete Warden [Thu, 12 Apr 2018 18:45:02 +0000 (11:45 -0700)]
Fixed error where no background audio samples were being used when testing no-speech clips

PiperOrigin-RevId: 192644704

6 years agoFix lost dependency
A. Unique TensorFlower [Thu, 12 Apr 2018 18:35:39 +0000 (11:35 -0700)]
Fix lost dependency

PiperOrigin-RevId: 192643127

6 years agoUpdate ops-related pbtxt files.
A. Unique TensorFlower [Thu, 12 Apr 2018 18:23:44 +0000 (11:23 -0700)]
Update ops-related pbtxt files.

PiperOrigin-RevId: 192640621

6 years agoFix shape inference for outside_compilation clusters that include cycles.
A. Unique TensorFlower [Thu, 12 Apr 2018 18:04:55 +0000 (11:04 -0700)]
Fix shape inference for outside_compilation clusters that include cycles.

PiperOrigin-RevId: 192637289

6 years agoMake default weights initializer in `base_layers.Layer` suitable for their dtype.
A. Unique TensorFlower [Thu, 12 Apr 2018 17:47:26 +0000 (10:47 -0700)]
Make default weights initializer in `base_layers.Layer` suitable for their dtype.

PiperOrigin-RevId: 192634133

6 years ago[TF] Add TensorListPushBackBatch.
Eugene Brevdo [Thu, 12 Apr 2018 17:35:41 +0000 (10:35 -0700)]
[TF] Add TensorListPushBackBatch.

Also modify code to ensure aliased forwarding happens whenever
possible with DT_VARIANT objects in ResourceVariables and in the new op.

PiperOrigin-RevId: 192632202

6 years agoIntroduced tool to run an HLO module in replicated fashion, by infeeding random data...
A. Unique TensorFlower [Thu, 12 Apr 2018 17:14:02 +0000 (10:14 -0700)]
Introduced tool to run an HLO module in replicated fashion, by infeeding random data and outfeeding the data generated at each step.
The arguments of the computation can be either read from the session module, or randomly generated.
The tool uses the raw transfer manager API to infeed and outfeed the data.

PiperOrigin-RevId: 192628605

6 years agoCollective Ops Part 3
A. Unique TensorFlower [Thu, 12 Apr 2018 16:46:34 +0000 (09:46 -0700)]
Collective Ops Part 3

BaseCollectiveExecutor and RingReducer.

This change is part of a series of changes introducing infrastructure
for collective ops and initial implementations of reduction and broadcast.

PiperOrigin-RevId: 192624521

6 years agoFixing dependencies.
A. Unique TensorFlower [Thu, 12 Apr 2018 16:44:16 +0000 (09:44 -0700)]
Fixing dependencies.

PiperOrigin-RevId: 192624191

6 years agoUpdating tests containing graphs with Variables so that they Evaluate the original...
A. Unique TensorFlower [Thu, 12 Apr 2018 15:49:47 +0000 (08:49 -0700)]
Updating tests containing graphs with Variables so that they Evaluate the original and optimized graphs and check if the outputs are same.

PiperOrigin-RevId: 192616402

6 years agoSpecial-case the name scoping for operator methods. TensorFlow disallows top-level...
A. Unique TensorFlower [Thu, 12 Apr 2018 13:22:30 +0000 (06:22 -0700)]
Special-case the name scoping for operator methods. TensorFlow disallows top-level name scopes to begin with underscores. Also use the transformer scope information to get to the enclosing function name.

PiperOrigin-RevId: 192600256

6 years agoMake DType, TensorShape, and Dimension "reducable" for pickling purposes.
A. Unique TensorFlower [Thu, 12 Apr 2018 11:40:42 +0000 (04:40 -0700)]
Make DType, TensorShape, and Dimension "reducable" for pickling purposes.

PiperOrigin-RevId: 192591402

6 years agoEnable an r2 reduce window test case.
A. Unique TensorFlower [Thu, 12 Apr 2018 05:37:57 +0000 (22:37 -0700)]
Enable an r2 reduce window test case.

PiperOrigin-RevId: 192560111

6 years agoFix description of DynamicUpdateSlice.
A. Unique TensorFlower [Thu, 12 Apr 2018 03:08:30 +0000 (20:08 -0700)]
Fix description of DynamicUpdateSlice.

PiperOrigin-RevId: 192550101

6 years agoAdd closure_js_proto_library build for tf.example protos.
James Wexler [Thu, 12 Apr 2018 02:58:07 +0000 (19:58 -0700)]
Add closure_js_proto_library build for tf.example protos.

PiperOrigin-RevId: 192549109

6 years agoEnable a reduce window test case.
A. Unique TensorFlower [Thu, 12 Apr 2018 02:50:10 +0000 (19:50 -0700)]
Enable a reduce window test case.

PiperOrigin-RevId: 192548652

6 years agoGo: Update generated wrapper functions for TensorFlow ops.
A. Unique TensorFlower [Thu, 12 Apr 2018 02:45:42 +0000 (19:45 -0700)]
Go: Update generated wrapper functions for TensorFlow ops.
PiperOrigin-RevId: 192548367

6 years agoUpdate ops-related pbtxt files.
A. Unique TensorFlower [Thu, 12 Apr 2018 02:18:20 +0000 (19:18 -0700)]
Update ops-related pbtxt files.

PiperOrigin-RevId: 192546579

6 years ago[XLA] Redesign: fix GetComputationGraphStats.
A. Unique TensorFlower [Thu, 12 Apr 2018 02:14:47 +0000 (19:14 -0700)]
[XLA] Redesign: fix GetComputationGraphStats.

CreateFromProto requires that the config has proper entry_computation_layout, so give the config the program shape.

PiperOrigin-RevId: 192546316

6 years agoSwitch to WaitForNotification to fix the flaky test.
Jonathan Hseu [Thu, 12 Apr 2018 01:57:49 +0000 (18:57 -0700)]
Switch to WaitForNotification to fix the flaky test.

See:
https://source.cloud.google.com/results/invocations/31632a30-3728-4635-a456-f89b9e8b9dfe/log
PiperOrigin-RevId: 192544848

6 years ago[XLA] Redesign: test sharding.
A. Unique TensorFlower [Thu, 12 Apr 2018 01:38:38 +0000 (18:38 -0700)]
[XLA] Redesign: test sharding.

Also set the sharding to the instruction when created from proto.

PiperOrigin-RevId: 192543024

6 years agoIncrease size of //tensorflow/python/kernel_tests:linalg_ops_test to "medium".
Derek Murray [Thu, 12 Apr 2018 01:37:47 +0000 (18:37 -0700)]
Increase size of //tensorflow/python/kernel_tests:linalg_ops_test to "medium".

PiperOrigin-RevId: 192542956

6 years agoIn model_to_estimator, only run get_weights when there are initialized Keras variable...
Yifei Feng [Thu, 12 Apr 2018 01:20:19 +0000 (18:20 -0700)]
In model_to_estimator, only run get_weights when there are initialized Keras variables(which assumes there exists a session). Otherwise create a session so that we can run get_config().
Actually fix #18193.

PiperOrigin-RevId: 192541442

6 years agoAdd `tf.contrib.stateless.stateless_multinomial()`.
Derek Murray [Thu, 12 Apr 2018 01:09:42 +0000 (18:09 -0700)]
Add `tf.contrib.stateless.stateless_multinomial()`.

This is a starting point for Dataset-compatible weighted sampling across a list of datasets.

PiperOrigin-RevId: 192540412

6 years agoInternal testing changes
Austin Anderson [Thu, 12 Apr 2018 00:46:08 +0000 (17:46 -0700)]
Internal testing changes

PiperOrigin-RevId: 192537874