Vortex nucleation in deformed rotating cylinders