Hearing a song is not copyright infringement.
Memorizing lyrics is not copyright infringement.
While you're absolutely right, the current state of copyright law and technology is at a disconnect. We're in a world where we need to convince people of such analogies (and even here on Slashdot the idea of hearing and memorizing isn't clear (I'm in the AI doesn't memorize department, it doesn't store an original copy), so that analogies start applying in a legal context.
What we need is for laws to actually exists which address this curious situation of a computer "learning" from what it sees or hears. Currently we don't have any which is producing wildly inconsistent outcomes across the legal field.