You also have to do a PhD, and make sure you get a good adviser/good department, and get lucky enough for nothing bad to happen to your adviser and department, and be very careful with how you spend your time (if you spend a lot of time on something that doesn't end up being fruitful, that's opportunity cost that other top researchers might have turned into a breakout publication and now you are behind). And you make like $30k/year while in grad school and might experience some pretty bad mental health due to stress.
Of course, the average/above-average case isn't terrible. I think non-famous AI researchers are still getting hired into $400-500k/year at FAANG at "senior" level, it's just that you would be making roughly the same amount of money if you just went directly into software engineering at a FAANG out of undergrad and did above-average at promotions.
To me, that makes it not really make sense to go into AI research (especially now, when it's a hot topic and you have a 3-5 year wait to get your PhD) unless it's something you are genuinely interested in. For purely career reasons, it doesn't seem much better than just going right into software engineering.