There’s a big difference between AI generated code that the human understands completely, the human understands mostly, or the human understands not at all.
I do this exercise myself for code that I really care about: after AI has written the code and I think I have achieved a full understanding, I unapply the entire patch and make sure I can reproduce the patch with the same underlying idea perhaps with less verbosity in the comments. That’s what I call fully understood. If I “mostly understand” some AI code, it means during the reproduction I need to occasionally look back at the AI code to continue.