class ConcatenationVertex extends VertexImpl<DoubleTensor, DoubleVertex> implements DoubleVertex, Differentiable, NonProbabilistic<DoubleTensor> {

    public static ForwardModePartialDerivative concat(List<ForwardModePartialDerivative> partialsOfOperands,
                                                      List<DoubleTensor> operandValues,
                                                      int dimension) {

        long[] wrtShape = null;
        for (int i = 0; i < partialsOfOperands.size(); i++) {
            ForwardModePartialDerivative partial = partialsOfOperands.get(i);

            if (partial.isPresent()) {
                wrtShape = partial.getWrtShape();
                break;
            }
        }

        List<DoubleTensor> partialsToConcat = getPartialsToConcatForInput(
            partialsOfOperands,
            operandValues,
            wrtShape
        );

        return new ForwardModePartialDerivative(wrtShape, concatPartialDerivatives(dimension + wrtShape.length, partialsToConcat));
    }

    @ExportVertexToPythonBindings public  ConcatenationVertex(@LoadVertexParam(DIMENSION_NAME) int dimension,
                               @LoadVertexParam(OPERANDS_NAME) Vertex<DoubleTensor, ?>... operands);

}