def stacks_to_pyramid_seq(stacks):
    """ Converts a list of stacked layers to a list of Laplacina pyramids. """
    pyramid_seq = list()
    nr_frames = len(stacks[0])

    for frame_idx in range(nr_frames):
        pyramid = list()

        for stack in stacks:
            pyramid.append(stack[frame_idx])

        pyramid_seq.append(pyramid)

    return pyramid_seq