message: Add reshape -1 and converts negative reduction indices.
diff: @@ -836,8 +836,9 @@ auto one = Const(scope, 1);
  // [2, 3, 2]
  auto input_shape = Shape(scope, op.input(0));
  + // The Reshape with -1 flattens the reduction indices.
  // [1]
  -auto reduction_indices = op.input(1);
  + auto reduction_indices = Reshape(scope, op.input(1), {-1});
  // [2, 1, 2]
  auto output_shape_kept_dims =
  @@ -857,8 +858,12 @@ Scope cpu_scope = scope.WithDevice("/cpu:0");
  // [3]
  auto rank = Rank(cpu_scope, op.input(0));
  +
  + // Normalize any negative indices in the reduction_axes to positive values.
  + auto reduction_indices_pos = Mod(scope, Add(scope, reduction_indices, rank), rank);
  +
  // [1]
  -auto reduced = Cast(cpu_scope, reduction_indices, DataType::DT_INT32);
  + auto reduced = Cast(cpu_scope, reduction_indices_pos, DataType::DT_INT32);
  // [0, 1, 2]
  auto idx = Range(cpu_scope, zero, rank, one);
  