public BaseBatches(TInput[] inputs, double[] weights) { if (weights != null) { if (inputs.Length != weights.Length) throw new DimensionMismatchException(); } else { weights = Vector.Ones(inputs.Length); } this.Inputs = inputs; this.Weights = weights; this.MiniBatchSize = 32; this.Shuffle = ShuffleMethod.OnlyOnce; this.NumberOfMiniBatches = (int)Math.Ceiling(Inputs.Length / (double)MiniBatchSize); }