next_minibatch: Next Minibatch

Description Usage Arguments Value

Description

Reads a minibatch that contains data for all input streams. The minibatch size is specified in terms of #samples and/or #sequences for the primary input stream; value of 0 for #samples/#sequences means unspecified. In case the size is specified in terms of both #sequences and #samples, the smaller of the 2 is taken. An empty map is returned when the MinibatchSource has no more data to return.

Usage

1
2
next_minibatch(minibatch_source, minibatch_size_in_samples, input_map = NULL,
  device = NULL, num_data_partitions = NULL, partition_index = NULL)

Arguments

minibatch_source

(MinibatchSource or MinibatchSourceFromData) source for minibatch

minibatch_size_in_samples

number of samples to retrieve for the next minibatch. Must be > 0.

input_map

mapping of Variable to StreamInformation which will be used to convert the returned data.

device

- instance of DeviceDescriptor

num_data_partitions

Used for distributed training, indicates into how many partitions the source should split the data.

partition_index

Used for distributed training, indicates data from which partition to take.

Value

(MinibatchData) mapping of StreamInformation to MinibatchData if input_map was not specified. Otherwise, the returned value will be a mapping of Variable to class:MinibatchData. When the maximum number of epochs/samples is exhausted, the return value is an empty dict.


Microsoft/CNTK-R documentation built on May 28, 2019, 1:52 p.m.