Home
last modified time | relevance | path

Searched refs:Dataset (Results 1 – 25 of 337) sorted by relevance

12345678910>>...14

/external/tensorflow/tensorflow/python/data/experimental/kernel_tests/
Dcardinality_test.py36 lambda: dataset_ops.Dataset.range(5).batch(2, drop_remainder=True), 2),
38 lambda: dataset_ops.Dataset.range(5).batch(2, drop_remainder=False), 3),
40 lambda: dataset_ops.Dataset.range(5).filter(lambda _: True).batch(2),
42 ("Batch4", lambda: dataset_ops.Dataset.range(5).repeat().batch(2),
44 ("Cache1", lambda: dataset_ops.Dataset.range(5).cache(), 5),
45 ("Cache2", lambda: dataset_ops.Dataset.range(5).cache("foo"), 5),
46 ("Concatenate1", lambda: dataset_ops.Dataset.range(5).concatenate(
47 dataset_ops.Dataset.range(5)), 10),
49 lambda: dataset_ops.Dataset.range(5).filter(lambda _: True).concatenate(
50 dataset_ops.Dataset.range(5)), cardinality.UNKNOWN),
[all …]
Ddirected_interleave_dataset_test.py35 selector_dataset = dataset_ops.Dataset.range(10).repeat(100)
37 dataset_ops.Dataset.from_tensors(i).repeat(100) for i in range(10)
63 dataset_ops.Dataset.from_tensors(i).repeat(None)
92 probs_ds = dataset_ops.Dataset.from_tensors(probs).repeat()
98 datasets = [dataset_ops.Dataset.from_tensors(w).repeat() for w in words]
100 choice_dataset = dataset_ops.Dataset.from_tensor_slices(choice_array)
112 [dataset_ops.Dataset.range(10),
113 dataset_ops.Dataset.range(20)],
118 [dataset_ops.Dataset.range(10),
119 dataset_ops.Dataset.range(20)],
[all …]
Drebatch_dataset_test.py43 dataset = dataset_ops.Dataset.range(1024).batch(
57 dataset = dataset_ops.Dataset.range(1024)
62 dataset = dataset_ops.Dataset.range(1024).batch(
72 dataset_ops.Dataset.range(1024).map(lambda x: (x, x)).batch(
81 dataset = dataset_ops.Dataset.range(1024).map(
91 dataset = dataset_ops.Dataset.range(1032).batch(
105 dataset = dataset_ops.Dataset.range(34).batch(
121 dataset = dataset_ops.Dataset.range(128).batch(
144 dataset = dataset_ops.Dataset.range(1024).apply(
159 dataset = dataset_ops.Dataset.range(128).batch(4).padded_batch(
[all …]
Dauto_shard_dataset_test.py51 dataset = dataset_ops.Dataset.list_files(self.test_filenames, shuffle=True)
64 dataset1 = dataset_ops.Dataset.list_files(self.test_filenames, shuffle=True)
67 dataset2 = dataset_ops.Dataset.list_files(self.test_filenames, shuffle=True)
71 dataset = dataset_ops.Dataset.zip((dataset1, dataset2))
83 dataset1 = dataset_ops.Dataset.list_files(self.test_filenames, shuffle=True)
87 dataset2 = dataset_ops.Dataset.list_files(self.test_filenames, shuffle=True)
104 dataset = dataset_ops.Dataset.list_files(self.test_filenames, shuffle=True)
119 dataset = dataset_ops.Dataset.range(self._num_files)
161 dataset = dataset_ops.Dataset.list_files(self.test_filenames, shuffle=True)
175 dataset = dataset_ops.Dataset.list_files(self.test_filenames, shuffle=True)
[all …]
Dgroup_by_reducer_test.py45 dataset = dataset_ops.Dataset.range(2 * i).apply(
63 dataset = dataset_ops.Dataset.range(2 * i).apply(
78 dataset = dataset_ops.Dataset.zip(
79 (dataset_ops.Dataset.from_tensor_slices(components),
80 dataset_ops.Dataset.range(2 * i))).apply(
99 dataset = dataset_ops.Dataset.range(2 * i).map(_sparse).apply(
121 dataset = dataset_ops.Dataset.from_tensors(np.int64(0)).repeat(i).apply(
139 dataset = dataset_ops.Dataset.range(10)
153 dataset = dataset_ops.Dataset.range(10)
166 dataset = dataset_ops.Dataset.range(10)
[all …]
/external/tensorflow/tensorflow/python/keras/engine/
Dtraining_utils_test.py103 ('Batch', lambda: dataset_ops.Dataset.range(5).batch(2), ValueError),
104 ('Cache', lambda: dataset_ops.Dataset.range(5).cache()),
105 ('Concatenate', lambda: dataset_ops.Dataset.range(5).concatenate(
106 dataset_ops.Dataset.range(5))),
107 ('FlatMap', lambda: dataset_ops.Dataset.range(5).flat_map(
108 lambda _: dataset_ops.Dataset.from_tensors(0)), ValueError),
109 ('Filter', lambda: dataset_ops.Dataset.range(5).filter(lambda _: True)),
112 ('FromTensors', lambda: dataset_ops.Dataset.from_tensors(0)),
114 lambda: dataset_ops.Dataset.from_tensor_slices([0, 0, 0])),
115 ('Interleave', lambda: dataset_ops.Dataset.range(5).interleave(
[all …]
/external/tensorflow/tensorflow/python/data/kernel_tests/
Ddataset_test.py45 dataset = dataset_ops.Dataset.range(10)
75 lambda x: dataset_ops.Dataset.range(0),
85 lambda: dataset_ops.Dataset.from_generator(
88 ("FromTensors", lambda: dataset_ops.Dataset.from_tensors([42])),
89 ("FromTensorSlices", lambda: dataset_ops.Dataset.from_tensors([42])),
90 ("Range", lambda: dataset_ops.Dataset.range(10)),
99 dataset_fn = dataset_ops.Dataset.from_sparse_tensor_slices(
109 lambda: dataset_ops.Dataset.range(0)),
112 lambda: dataset_ops.Dataset.range(0)),
115 lambda: dataset_ops.Dataset.range(0)),
[all …]
Dshard_test.py31 dataset = dataset_ops.Dataset.range(10).shard(5, 2)
35 dataset_a = dataset_ops.Dataset.range(10)
36 dataset_b = dataset_ops.Dataset.range(10, 0, -1)
37 dataset = dataset_ops.Dataset.zip((dataset_a, dataset_b)).shard(5, 2)
41 dataset = dataset_ops.Dataset.range(10).shard(5, 0)
46 dataset = dataset_ops.Dataset.range(10).shard(5, 7)
51 dataset = dataset_ops.Dataset.range(10).shard(5, -3)
56 dataset = dataset_ops.Dataset.range(10).shard(-3, 1)
61 dataset = dataset_ops.Dataset.range(10).shard(0, 1)
65 dataset = dataset_ops.Dataset.range(1).shard(5, 2)
[all …]
Dflat_map_test.py42 dataset = dataset_ops.Dataset.from_tensor_slices(components).flat_map(
43 lambda x: dataset_ops.Dataset.from_tensors([x]).repeat(x))
52 dataset = dataset_ops.Dataset.from_tensor_slices(components).flat_map(
53 lambda x: dataset_ops.Dataset.from_tensor_slices(x).flat_map(
54 lambda y: dataset_ops.Dataset.from_tensors(y).repeat(y))
69 dataset_ops.Dataset.from_tensor_slices(components).flat_map(
70 lambda x: dataset_ops.Dataset.from_tensor_slices(x).flat_map(
71 lambda y: dataset_ops.Dataset.from_tensors(y).repeat(y))),
97 dataset = dataset_ops.Dataset.range(10).map(
99 lambda d: dataset_ops.Dataset.from_tensors(
[all …]
Dfrom_generator_test.py41 dataset = dataset_ops.Dataset.from_generator(
50 dataset = dataset_ops.Dataset.from_generator(
105 return (dataset_ops.Dataset.from_generator(
110 dataset = dataset_ops.Dataset.range(num_outer_repeats).interleave(
159 return dataset_ops.Dataset.from_generator(
162 dataset = dataset_ops.Dataset.range(num_parallel_iterators).interleave(
179 dataset = dataset_ops.Dataset.from_generator(
196 dataset = dataset_ops.Dataset.from_generator(
208 dataset = dataset_ops.Dataset.from_generator(
228 dataset = dataset_ops.Dataset.from_generator(
[all …]
Drange_test.py31 dataset = dataset_ops.Dataset.range(5)
36 dataset = dataset_ops.Dataset.range(start, stop)
41 dataset = dataset_ops.Dataset.range(start, stop, step)
47 dataset = dataset_ops.Dataset.range(start, stop, step)
52 dataset = dataset_ops.Dataset.range(start, stop, step)
57 dataset = dataset_ops.Dataset.range(start, stop)
62 dataset = dataset_ops.Dataset.range(start, stop, step)
67 dataset = dataset_ops.Dataset.range(start, stop, step)
Dmap_test.py82 dataset = dataset_ops.Dataset.range(num_elements).map(
96 dataset = dataset_ops.Dataset.from_tensor_slices(components).map(
161 dataset = dataset_ops.Dataset.from_tensor_slices(components).map(
262 dataset = (dataset_ops.Dataset.from_tensor_slices(components)
273 dataset = (dataset_ops.Dataset.from_tensor_slices(components)
290 dataset = (dataset_ops.Dataset.from_tensor_slices(components)
313 return dataset_ops.Dataset.range(10).map(_map_fn)
317 captured_iterator = iter(dataset_ops.Dataset.range(10))
320 dataset_ops.Dataset.range(10))
343 input_sentences = dataset_ops.Dataset.from_tensor_slices(
[all …]
Dconcatenate_test.py44 input_dataset = dataset_ops.Dataset.from_tensor_slices(input_components)
45 dataset_to_concatenate = dataset_ops.Dataset.from_tensor_slices(
75 input_dataset = dataset_ops.Dataset.from_tensor_slices(input_components)
76 dataset_to_concatenate = dataset_ops.Dataset.from_tensor_slices(
106 input_dataset = dataset_ops.Dataset.from_tensor_slices(input_components)
107 dataset_to_concatenate = dataset_ops.Dataset.from_tensor_slices(
123 input_dataset = dataset_ops.Dataset.from_tensor_slices(input_components)
124 dataset_to_concatenate = dataset_ops.Dataset.from_tensor_slices(
138 input_dataset = dataset_ops.Dataset.from_tensor_slices(input_components)
139 dataset_to_concatenate = dataset_ops.Dataset.from_tensor_slices(
Dlist_files_test.py49 dataset = dataset_ops.Dataset.list_files(path.join(self.tmp_dir, '*'))
56 dataset = dataset_ops.Dataset.list_files(path.join(self.tmp_dir, '*'))
69 dataset = dataset_ops.Dataset.list_files(
82 dataset = dataset_ops.Dataset.list_files(
112 return dataset_ops.Dataset.list_files(path.join(self.tmp_dir, '*'))
124 dataset = dataset_ops.Dataset.list_files(path.join(self.tmp_dir, '*'))
137 dataset = dataset_ops.Dataset.list_files(path.join(self.tmp_dir, '*.py'))
150 dataset = dataset_ops.Dataset.list_files(path.join(self.tmp_dir, '*.py*'))
172 dataset = dataset_ops.Dataset.list_files(
193 dataset = dataset_ops.Dataset.list_files(patterns)
[all …]
Doptions_test.py32 ds = dataset_ops.Dataset.range(0)
37 ds = dataset_ops.Dataset.range(0).with_options(options).cache()
43 ds = dataset_ops.Dataset.range(0).with_options(options).with_options(
52 ds = dataset_ops.Dataset.range(0).with_options(options1).with_options(
65 dataset_ops.Dataset.range(0).with_options(options1).with_options(options2)
72 ds = dataset_ops.Dataset.zip(
73 (dataset_ops.Dataset.range(0).with_options(options1),
74 dataset_ops.Dataset.range(0).with_options(options2)))
/external/tensorflow/tensorflow/python/data/experimental/kernel_tests/serialization/
Dflat_map_dataset_serialization_test.py42 return dataset_ops.Dataset.range(x, x + 5)
44 return dataset_ops.Dataset.range(start, start + 5 * 5, 5).flat_map(map_fn)
57 return dataset_ops.Dataset.range(100).map(map_fn)
59 return dataset_ops.Dataset.range(5).flat_map(flat_map_fn)
73 return dataset_ops.Dataset.from_tensor_slices([defun_fn(x)])
75 return dataset_ops.Dataset.range(100).flat_map(map_fn)
84 return dataset_ops.Dataset.range(5).flat_map(
85 lambda _: dataset_ops.Dataset.from_tensor_slices([test_var]))
99 return dataset_ops.Dataset.range(100).map(map_fn)
101 return dataset_ops.Dataset.range(5).flat_map(flat_map_fn)
[all …]
/external/tensorflow/tensorflow/contrib/eager/python/
Ddatasets_test.py28 from tensorflow.python.data import Dataset
47 for t in datasets.Iterator(Dataset.range(4)):
53 for t in Dataset.range(4).make_one_shot_iterator():
59 for t in Dataset.range(4):
64 iterator = datasets.Iterator(Dataset.range(4))
73 iterator = Dataset.range(4).make_one_shot_iterator()
82 ds = Dataset.range(4)
92 ds = Dataset.zip((Dataset.range(4), Dataset.zip((Dataset.range(4),
93 Dataset.range(4)))))
108 it = datasets.Iterator(Dataset.range(8).map(math_ops.square).filter(even))
[all …]
/external/tensorflow/tensorflow/python/data/experimental/kernel_tests/optimization/
Doptimize_dataset_test.py51 return dataset_ops.Dataset.from_tensors(0).map(lambda x: x + var)
54 return dataset_ops.Dataset.from_tensors(
55 0).flat_map(lambda _: dataset_ops.Dataset.from_tensors(var))
58 return dataset_ops.Dataset.from_tensors(0).filter(lambda x: x < var)
65 return dataset_ops.Dataset.from_tensors(0).apply(
73 return dataset_ops.Dataset.range(5).apply(
80 return dataset_ops.Dataset.from_tensors(var)
82 return dataset_ops.Dataset.from_tensors(0).repeat(10).apply(
86 return dataset_ops.Dataset.from_tensors(0).apply(
107 dataset = dataset_ops.Dataset.range(
[all …]
Dmap_vectorization_test.py108 return dataset_ops.Dataset.from_tensor_slices(random_int)
111 return dataset_ops.Dataset.from_tensor_slices(random_input > 0)
114 return dataset_ops.Dataset.from_tensor_slices(random_input)
117 return dataset_ops.Dataset.from_tensor_slices(
187 return dataset_ops.Dataset.from_tensors((x_int, y_int))
190 return dataset_ops.Dataset.from_tensors((x > 0, y > 0))
193 return dataset_ops.Dataset.from_tensors((x, y))
213 return dataset_ops.Dataset.from_tensor_slices(["1.0:2:a",
245 return dataset_ops.Dataset.from_tensor_slices(
268 return dataset_ops.Dataset.from_tensors(np.random.rand(10, 3)).repeat(5)
[all …]
/external/tensorflow/tensorflow/python/data/util/
Dtraverse_test.py46 ds = dataset_ops.Dataset.range(10)
52 ds = dataset_ops.Dataset.range(10).map(math_ops.square)
60 ds1 = dataset_ops.Dataset.range(10)
61 ds2 = dataset_ops.Dataset.range(10)
70 ds1 = dataset_ops.Dataset.range(10)
71 ds2 = dataset_ops.Dataset.range(10)
72 ds = dataset_ops.Dataset.zip((ds1, ds2))
80 ds = dataset_ops.Dataset.range(10)
89 ds1 = dataset_ops.Dataset.range(10).repeat(10)
98 ds2 = dataset_ops.Dataset.range(20).prefetch(1)
/external/tensorflow/tensorflow/contrib/distribute/python/
Dinput_lib_test.py107 dataset_fn = lambda _: dataset_ops.Dataset.range(10)
120 dataset_fn = lambda _: dataset_ops.Dataset.range(10)
136 dataset1 = dataset_ops.Dataset.range(10)
137 dataset2 = dataset_ops.Dataset.range(10).map(lambda x: x**2)
138 return dataset_ops.Dataset.zip((dataset1, dataset2))
152 dataset_fn = lambda _: dataset_ops.Dataset.range(9).batch(2)
167 dataset_fn = lambda _: dataset_ops.Dataset.range(100).batch(batch_size)
209 dataset_fn = lambda _: dataset_ops.Dataset.range(4)
220 dataset_fn = lambda _: dataset_ops.Dataset.range(4)
233 dataset1 = dataset_ops.Dataset.range(4)
[all …]
/external/tensorflow/tensorflow/core/kernels/data/experimental/
Dthreadpool_dataset_op.cc135 *output = new Dataset(ctx, input, ctx->input(1), threadpool_resource); in MakeDataset()
139 class Dataset : public DatasetBase { class in tensorflow::data::__anon808a52080111::ThreadPoolDatasetOp
141 Dataset(OpKernelContext* ctx, const DatasetBase* input, in Dataset() function in tensorflow::data::__anon808a52080111::ThreadPoolDatasetOp::Dataset
151 ~Dataset() override { in ~Dataset()
189 class Iterator : public DatasetIterator<Dataset> {
192 : DatasetIterator<Dataset>(params) {} in Iterator()
247 *output = new Dataset(ctx, input, max_intra_op_parallelism); in MakeDataset()
251 class Dataset : public DatasetBase { class in tensorflow::data::__anon808a52080111::MaxIntraOpParallelismDatasetOp
253 Dataset(OpKernelContext* ctx, const DatasetBase* input, in Dataset() function in tensorflow::data::__anon808a52080111::MaxIntraOpParallelismDatasetOp::Dataset
261 ~Dataset() override { input_->Unref(); } in ~Dataset()
[all …]
Dstats_dataset_ops.cc46 *output = new Dataset(ctx, input, std::move(tag)); in MakeDataset()
50 class Dataset : public DatasetBase { class in tensorflow::data::__anon95544c980111::LatencyStatsDatasetOp
52 explicit Dataset(OpKernelContext* ctx, const DatasetBase* input, string tag) in Dataset() function in tensorflow::data::__anon95544c980111::LatencyStatsDatasetOp::Dataset
59 ~Dataset() override { input_->Unref(); } in ~Dataset()
93 class Iterator : public DatasetIterator<Dataset> {
96 : DatasetIterator<Dataset>(params) {} in Iterator()
156 *output = new Dataset(ctx, input, std::move(tag)); in MakeDataset()
160 class Dataset : public DatasetBase { class in tensorflow::data::__anon95544c980111::BytesProducedStatsDatasetOp
162 explicit Dataset(OpKernelContext* ctx, const DatasetBase* input, string tag) in Dataset() function in tensorflow::data::__anon95544c980111::BytesProducedStatsDatasetOp::Dataset
169 ~Dataset() override { input_->Unref(); } in ~Dataset()
[all …]
/external/tensorflow/tensorflow/core/common_runtime/data/
Dstandalone.h65 class Dataset; variable
76 friend class Dataset;
86 class Dataset {
97 std::unique_ptr<Dataset>* result);
99 ~Dataset();
105 Dataset(DatasetBase* dataset, DeviceMgr* device_mgr,
Dstandalone.cc42 Status Dataset::FromGraph(Params params, const GraphDef& graph_def, in FromGraph()
44 std::unique_ptr<Dataset>* result) { in FromGraph()
79 WrapUnique(new Dataset(dataset, device_mgr.release(), pflr.release(), in FromGraph()
84 Status Dataset::MakeIterator(std::unique_ptr<Iterator>* result) { in MakeIterator()
111 Dataset::Dataset(DatasetBase* dataset, DeviceMgr* device_mgr, in Dataset() function in tensorflow::data::standalone::Dataset
124 Dataset::~Dataset() { dataset_->Unref(); } in ~Dataset()

12345678910>>...14