| Commit message (Collapse) | Author | Age |
|
|
|
|
|
| |
Fixes #20218
PiperOrigin-RevId: 211010451
|
|
|
|
| |
PiperOrigin-RevId: 210703993
|
|
|
|
| |
PiperOrigin-RevId: 210501378
|
|
|
|
| |
PiperOrigin-RevId: 210373905
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Back-ticks are now converted to links in the api_docs generator. With the new docs repo we're moving to simplify the docs pipeline, and make everything more readable.
By doing this we no longer get test failures for symbols that don't exist (`tf.does_not_exist` will not get a link).
There is also no way, not to set custom link text. That's okay.
This is the result of the following regex replacement (+ a couple of manual edits.):
re: @\{([^$].*?)(\$.+?)?}
sub: `\1`
Which does the following replacements:
"@{tf.symbol}" --> "`tf.symbol`"
"@{tf.symbol$link_text}" --> "`tf.symbol`"
PiperOrigin-RevId: 208042358
|
|
|
|
| |
PiperOrigin-RevId: 207971672
|
|
|
|
|
|
|
|
|
|
|
| |
Adopts a minimal sensible policy for step containers: starting a graident tape
creates a step container; inner tapes do nothing; popping out of the outermost
tape will reset that step container. This should allow us to have reasonable
behavior in the presence of step-container-scoped things for a while. Ideally
we'll move away from them in favor of lists but the infrastructure isn't ready
yet.
PiperOrigin-RevId: 207911091
|
|
|
|
|
|
|
|
|
| |
Any time that the server def is updated, the context is effectively "reset" by clearing all the caches.
- Check that the FLR returned is not a nullptr instead of seg faulting.
- Consolidate caches within the context object.
PiperOrigin-RevId: 207308086
|
|
|
|
|
|
|
|
|
|
|
| |
At times, a server cannot open a reverse connection to the client. This is
required when using the _Send/_Recv ops and the client needs to send a tensor
to the server (tensors are pulled). Instead, this adds a way to push the
tensors directly from the client.
Currently, pushing tensors always happens in sync mode.
PiperOrigin-RevId: 205888825
|
|
|
|
|
|
| |
the grpc_tensorflow_server.
PiperOrigin-RevId: 201198350
|
|
|
|
|
|
| |
Minor fixes to make this work.
PiperOrigin-RevId: 191457070
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Call _context_handle in the fastpath. Fall back to slow path if it is not
initialized.
A better fix would be to not initialize handle and devices lazily (and not
have to pay that function call in the slow path either), but that
seems to break all GPU/TPU tests. I'm not as yet really familiar with how
devices are recognized, but I'd be happy to hear any ideas you may have to
fix this.
- context.context() is monkey patched to remove the "is None" check once we
know the context is correctly initialized. Ideally we would be able to remove
this function call as well.
- Maintain is_eager instead of doing the comparison every time. Also, in the
fastpath, inline the check directly instead of paying the function call cost.
- Inline _eager_context.device_name instead of get the device_name property to
not pay the function call cost
gen_array_ops.identity Old: 216706.923837 examples/sec (4.61452722549)
gen_array_ops.identity New: 290819.129714 examples/sec (3.43856334686)
PiperOrigin-RevId: 191336857
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This change provides an alternative mechanism to
tf.raise_exception_on_not_ok_status(), which is inefficient and
error-prone (people often use the status multiple times in the with
block, but it's only checked when the context manager exits). Instead,
it uses SWIG to automatically raise an exception when a C API method
fails. Note that this removes the status argument from affected
methods.
For now, I've only applied this typemap to C API methods. It would be
good to expand this to all uses of raise_exception_on_not_ok_status.
PiperOrigin-RevId: 191121016
|
|
|
|
| |
PiperOrigin-RevId: 190707017
|
|
|
|
|
|
|
|
|
|
|
| |
When eager execution is enabled in the main thread, the fact that it was
enabled is propagated to subsequently created threads. This
change ...
(1) ensures that the fact that eager was enabled is also propagated to the `ContextStack`, which is renamed to `_ContextSwitchStack`, for clarity;
(2) adds a `_ContextSwitchStack` object to `Context` as a member, removing the global `context_stack`.
PiperOrigin-RevId: 189206207
|
|
|
|
| |
PiperOrigin-RevId: 189101670
|
|
|
|
| |
PiperOrigin-RevId: 188255674
|
|
|
|
|
|
|
|
| |
This is in preparation to introduce one public, stable symbol: tf.executing_eagerly()
(i.e., part of moving APIs related to eager execution from "contrib" to a namespace
where we provide API stability guarantees)
PiperOrigin-RevId: 188212646
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
Before:
entry {
name: "EagerLinearRegressionBenchmark.eager_train_cpu"
iters: 2000
wall_time: 2.45178794861
extras {
key: "examples_per_sec"
value {
double_value: 52206.7987456
}
}
}
After:
entry {
name: "EagerLinearRegressionBenchmark.eager_train_cpu"
iters: 2000
wall_time: 1.9873790741
extras {
key: "examples_per_sec"
value {
double_value: 64406.4344182
}
}
}
PiperOrigin-RevId: 188068838
|
|
|
|
| |
PiperOrigin-RevId: 186833677
|
|
|
|
| |
PiperOrigin-RevId: 186062850
|
|
|
|
| |
PiperOrigin-RevId: 185260675
|
|
|
|
|
|
| |
Fixes #16106
PiperOrigin-RevId: 183137298
|
|
|
|
| |
PiperOrigin-RevId: 183126126
|
|
|
|
| |
PiperOrigin-RevId: 183126037
|
|
|
|
| |
PiperOrigin-RevId: 183093407
|
|
|
|
| |
PiperOrigin-RevId: 181770918
|
|
|
|
| |
PiperOrigin-RevId: 181317960
|
|
|
|
|
|
| |
"big hammer" required for reproducibility.
PiperOrigin-RevId: 180961787
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
There is often a need to lift variable initialization ops out of control
flow contexts, graphs that are building functions, and gradient tapes.
Entering an `init_scope` is a mechanism for satisfying these desiderata. In
particular, entering an `init_scope` has three effects:
(1) All control dependencies are cleared the moment the scope is entered;
this is equivalent to entering the manager returned from
`control_dependencies(None)`, which is how we exit control-flow contexts like
`tf.while_loop` and `tf.cond`.
(2) All operations that are created while the scope is active are lifted
into the lowest context on the `context_stack` that is not building a
graph function.
(3) The gradient tape is paused while the scope is active.
In (2), a context is defined as either a graph or an eager context. Every
context switch, i.e., every installation of a graph as the default graph and
every switch into eager mode, is logged in a thread-local stack called
the `context_stack`; the log entry for a context switch is popped from the
stack when the context is exited. Entering an `init_scope`, with respect to
(2), is equivalent to crawling up the `context_stack`, finding the first
context that is not building a graph function, and entering it.
PiperOrigin-RevId: 179104270
|
|
|
|
|
|
| |
Rolls back the rollback with some swiggery to get python3 to work.
PiperOrigin-RevId: 177470328
|
|
|
|
| |
PiperOrigin-RevId: 177418947
|
|
|
|
| |
PiperOrigin-RevId: 177375237
|
|
|
|
| |
PiperOrigin-RevId: 173129793
|
|
|
|
| |
PiperOrigin-RevId: 172943398
|
|
|
|
| |
PiperOrigin-RevId: 172818175
|
|
|
|
|
|
| |
It is otherwise idempotent.
PiperOrigin-RevId: 172757241
|
|
|
|
| |
PiperOrigin-RevId: 171698189
|
|
|
|
|
|
|
|
| |
Without this change, if TensorFlow is compiled with support for other devices
(such with XLA, which makes XLA_CPU and XLA_GPU devices available), then
tfe.num_gpus() was incorrectly overcounting the number of available GPUs.
PiperOrigin-RevId: 171373389
|
|
|
|
| |
PiperOrigin-RevId: 170617321
|
|
|
|
|
|
| |
Also, move some TODO items out of doc strings of public methods.
PiperOrigin-RevId: 169094945
|
|
|
|
| |
PiperOrigin-RevId: 168834147
|
|
|
|
| |
PiperOrigin-RevId: 168422582
|
|
|
|
| |
PiperOrigin-RevId: 168154345
|
|
|
|
| |
PiperOrigin-RevId: 168065417
|
|
|
|
|
|
|
|
| |
This will allow function registration from other
modules without having to import "function.py".
(And besides, the function really does belong on the context).
PiperOrigin-RevId: 168040411
|
|
|
|
|
|
| |
The function errorred out because the undocumented name "context" was removed in tfe.py.
PiperOrigin-RevId: 168021533
|
|
|
|
|
|
| |
merging.
PiperOrigin-RevId: 167912007
|
|
|
|
| |
PiperOrigin-RevId: 167340103
|
|
|
|
| |
PiperOrigin-RevId: 165951046
|