xnn.common.train.graphed.PaddedCollate#

class xnn.common.train.graphed.PaddedCollate(planner, cap)[source]#

Bases: object

Collate structures into a batch of fixed counts with its index plan.

The real structures come first, as in collate(), followed by one padding structure (padding_structure()); the plan of the batch (from the structures’ own plans, PlannedDataset) is padded and attached as index_plan, its fixed sizes (Python integers, so that the model reads no value from the device) as index_sizes, and the real counts as real_atoms, real_edges and real_graphs (strip_padding()). Runs in the data-loader workers.

Parameters:
  • planner (callable) – The model’s index planner.

  • cap (Capacity) – The fixed counts.

padded#

plain batches (training went on with ordinary steps).

Type:

Off