Commit 181ca305 authored by Yong Tang's avatar Yong Tang
Browse files

Add shape validation in shape function of MapAndBatchDataset



In MapAndBatchDataset, batch_size, num_parallel_batches,
and drop_remainder are 0-D scalars. This fix adds
the shape check to those Inputs.

Note since the Input of `other_arguments` is a list and is
before `batch_size`, the shape of the `batch_size` and others
could not be obtained through index like `c->input(2)` etc directly.
It is still possible to obtain the ShapeHandle with names `c->input("batch_size", &batch_size)`,
though.

Signed-off-by: default avatarYong Tang <yong.tang.github@outlook.com>
parent d8fac4cb
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment