Pope leaves hospital after hernia operation