| Commit message (Collapse) | Author | Age |
... | |
| |
| |
| |
| |
| |
| |
| |
| | |
self.test_session() has been deprecated in 9962eb5e84b15e309410071b06c2ed2d6148ed44 as its name confuses readers of the test. Moving to cached_session() instead which is more explicit about:
* the fact that the session may be reused.
* the session is not closed even when doing a "with self.test_session()" statement.
PiperOrigin-RevId: 212336258
|
| |
| |
| |
| | |
PiperOrigin-RevId: 212177437
|
| |
| |
| |
| | |
PiperOrigin-RevId: 212054927
|
| |
| |
| |
| |
| |
| | |
removing unused `graph_def_version` field
PiperOrigin-RevId: 212054031
|
|/
|
| |
The examples in interleave are quite helpful. I just added a reference to this example
|
|
|
|
|
|
|
|
| |
`tf.data.Dataset.interleave`.
Unlike the `tf.data.contrib.parallel_interleave` whose parallelism is tied to the `cycle_length` argument, the newly introduced `num_parallel_calls` argument of `tf.data.Dataset.interleave` is decoupled from the `cycle_length` argument and identifies the degree of parallelism to use for fetching output elements.
PiperOrigin-RevId: 211886816
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
- Remove unnecessary use of test_session() in tests that run with eager
execution enabled.
- Use cached_session() instead of test_session()
(self.test_session() has been deprecated in
9962eb5e84b15e309410071b06c2ed2d6148ed44 as its name confuses readers of the
test. Moving to cached_session() instead which is more explicit about:
* the fact that the session may be reused.
* the session is not closed even when doing a "with self.test_session()"
statement.)
PiperOrigin-RevId: 211562969
|
|
|
|
|
|
| |
`MapDataset`.
PiperOrigin-RevId: 211520001
|
|
|
|
|
|
|
|
|
| |
input datasets are of type dictionaries with different set of key(s).
FIXES #20626
REL_NOTES: bug fix in `tf.data.Dataset.concatenate()`, now throws error if trying to concatenate two datasets of type dictionaries with different set of key(s).
PiperOrigin-RevId: 209845337
|
|
|
|
|
|
| |
self.test_session() has been deprecated in cl/208545396 as its behavior confuses readers of the test. Moving to self.session() instead.
PiperOrigin-RevId: 209696110
|
|
|
|
|
|
|
|
|
|
| |
Previously, a function instantiation error (e.g. in `Dataset.map()`) would lead
to an error in each GetNext() call that attempted to use the function. Moving this
to iterator instantiation time has the benefit that the error will be reported
once when the initialization op is executed, which has a more helpful stack
trace, since it should not be conflated with other potential op failures.
PiperOrigin-RevId: 209633511
|
|
|
|
|
|
|
|
|
|
| |
This change adds the skeleton implementation of `Structure` for
tensors, sparse tensors, and nests. Future changes will (i) add
structure representations for `Dataset` and `Optional`, (ii) add
support for registering custom types, and (iii) switch
`Dataset`, `Iterator`, and `Optional` to use `Structure` internally.
PiperOrigin-RevId: 209281967
|
|
|
|
|
|
|
|
|
|
| |
This change contains no code changes. Only doc-strings.
We can't use relative links in code files, so we don't have much choice but to link to tensorflow.org/
The deleted links were to docs that no longer exist.
PiperOrigin-RevId: 209019572
|
|
|
|
|
|
|
|
|
| |
Rollback breaking change.
END_PUBLIC
Automated rollback of commit 20622daa9db9d403a66111f5682367566e2bb8db. Revert #21038.
PiperOrigin-RevId: 208256026
|
|\
| |
| |
| | |
PiperOrigin-RevId: 208232199
|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
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: 207984120
|
| | |
| | |
| | |
| | | |
PiperOrigin-RevId: 207490563
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Dataset.list_files() matches no files.
The main effect of this change is to change a late `OutOfRangeError` at iteration time into an earlier `InvalidArgumentError` at initialization time, which will improve error reporting in Eager mode and high-level APIs that control the training loop (Estimator, Keras, etc.). This change will break some advanced uses that concatenate many potentially empty file listings, but it is possible to work around this using `tf.data.Dataset.from_tensor_slices(tf.matching_files(file_pattern))`. We expect that the improved productivity from an earlier, more actionable error message will outweigh the inconvenience of modifying a small number of existing programs.
PiperOrigin-RevId: 207344116
|
| | |
| | |
| | |
| | | |
PiperOrigin-RevId: 207320100
|
| | |
| | |
| | |
| | |
| | |
| | | |
Pure refactor, in preparation for adding a higher level checkpoint management utility. This utility will also need to work with the Checkpoint proto, and globbing it on to saver.py seems dirty.
PiperOrigin-RevId: 207179646
|
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
The `Optional` type makes it possible to represent missing values (e.g. an attempt to run `Iterator.get_next()` after the sequence has ended) without raising an error.
NOTE: The `Optional` type is currently only supported on CPU, and a follow-up change will add support for other devices. After then, we will add this to the `tf.contrib.data` API, with a view to eventually migrating it to core.
PiperOrigin-RevId: 207049979
|
| | |
| | |
| | |
| | |
| | |
| | | |
Use object-based save/restore to make dataset/iterator checkpointable in both graph as well as eager mode.
PiperOrigin-RevId: 206998349
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
CUDA test.
The GPU-using unit test was not being executed as a presubmit.
PiperOrigin-RevId: 206704667
|
| | |
| | |
| | |
| | |
| | |
| | | |
interpolation.
PiperOrigin-RevId: 206120307
|
| |/
|/|
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| |
| | |
1. Implement wrapper class `PythonFunc` to store Tout list
for appropriate dtype conversion from tensorflow types to
numpy types using the `dtype.as_numpy_dtype` member.
2. Adjust BUILD file to include py_test of the script_ops_test.
3. Add script_ops_test to illustrate broken behavior (see
`test_convert_empty_list`). Run the specific test suite with:
bazel test //tensorflow/python:script_ops_test
4. `_convert` was being called from dataset_ops, update this to
refer to the `PythonFunc` instead of the `FuncRegistry`.
5. [Review Feedback] Move script_ops tests to py_func_test.py. Also
removed the BUILD rules for the deleted test file.
|
| |
| |
| | |
Line was too long
|
| |
| |
| |
| |
| |
| | |
being there.
PiperOrigin-RevId: 205331171
|
| |
| |
| |
| |
| |
| | |
This CL gets rid of the forced placement of all eager datasets / iterators on the CPU since now we can have some datasets on the GPU.
PiperOrigin-RevId: 205264791
|
| |
| |
| |
| | |
PiperOrigin-RevId: 205011204
|
|/ |
|
|
|
|
|
|
|
|
| |
function calls to copy data from one device to another. Used in combination with PrefetchDataset, this can serve as a replacement for PrefetchToDeviceDataset.
This also adds GPU kernel registrations for some iterator ops and for GeneratorDataset and PrefetchDataset
PiperOrigin-RevId: 203538112
|
|
|
|
| |
PiperOrigin-RevId: 203525056
|
|
|
|
|
|
|
|
| |
This change introduces the `window` tf.data transformation, which can be used to create windows of elements (represented as a dataset) from a dataset. This transformation enables applying different batching logic to different components of a dataset.
To illustrate the benefits of the transformation, this CL also introduces transformations for batching and padded batching of windows of both dense and sparse tensors. Notably, padded batching of sparse tensors was previously not possible.
PiperOrigin-RevId: 203179522
|
|
|
|
|
|
|
|
| |
documentation.
Fixes #20265.
PiperOrigin-RevId: 202695249
|
|
|
|
|
|
| |
batches correctly.
PiperOrigin-RevId: 202688283
|
|
|
|
| |
PiperOrigin-RevId: 201994101
|
|
|
|
|
|
| |
Update references in source files and docs in tensorflow and related projects.
PiperOrigin-RevId: 201766994
|
|
|
|
| |
PiperOrigin-RevId: 201652888
|
|
|
|
|
|
|
|
|
|
| |
functional change.
This change adds experimental support in `StructuredFunctionWrapper` for taking datasets as function arguments and returning them, which is a stepping stone to creating datasets of datasets. However, the public API for such datasets (in particular how introspection using `Dataset.output_classes` etc. would work) is not settled, so this change only uses the new support in the implementation of `Dataset.flat_map()` and `tf.contrib.data.group_by_window()`.
The change also folds some code into its sole point of use in `StructuredFunctionWrapper`.
PiperOrigin-RevId: 201613301
|
|
|
|
|
|
| |
`tf.data.Dataset.padded_batch`.
PiperOrigin-RevId: 201544952
|
|
|
|
| |
PiperOrigin-RevId: 200642171
|
|
|
|
| |
PiperOrigin-RevId: 200639895
|
|
|
|
|
|
|
|
| |
enhancements to Defun.
This cuts down further on the boilerplate in functional tf.data transformations.
PiperOrigin-RevId: 200571420
|
|
|
|
|
|
| |
The `defun_args()` helper flattens a nested structure down into the flat tuple of tensor types expected by `Defun`.
PiperOrigin-RevId: 200441074
|
|
|
|
|
|
| |
This cuts down on the amount of repeated (or near-repeated) code in Dataset wrappers.
PiperOrigin-RevId: 200424152
|
|
|
|
|
|
| |
into a helper.
PiperOrigin-RevId: 200386950
|
|
|
|
| |
PiperOrigin-RevId: 200213440
|
|
|
|
|
|
|
|
|
|
| |
In particular:
* Improve the error message when the generator yields something with the wrong
structure.
* Improve the error message when the generator yields something with the wrong
element type.
PiperOrigin-RevId: 200124096
|
|
|
|
|
|
| |
`tf.data.Dataset.padded_batch()`, deprecating tf.contrib.data.batch_and_drop_remainder()` and `tf.contrib.data.padded_batch_and_drop_remainder()`.
PiperOrigin-RevId: 199871303
|