bugfix in the determination of the output dimensions
bugfix in the determination of the output dimensions