Learning student names was very difficult for me, but I would tell them on day one that I am not good with names. I would give myself two weeks and not reference the names until I was lecturing. I started using the students name inside my lecture using them as examples. That gave me a couple weeks to learn the names and associate it with their faces, I also got to impress them with my memory recall after announcing i'm not good with names, and it also is good as an attention grabber if I see somebody texting and use their name in class to point out I know they are not paying attention.