Is it legal to use mugshots without permission?

My friend in high school made an art piece that was a child's face made out of convicted sex offenders that were available for public use. That was just art for a high schooler. But my question is could it be used commercially. Say I wanted to make a similar art piece as a cover for a book, would it be legal to use them?