Initially Google AdSense may not display ads on pages with NSFW content, however, they may disable your account as publisher complaints arise, especially for highly visited pages, which will impact your entire website, not just the pages with NSFW content.
There are reports of much less than 10% of NSFW pages resulting in disabled accounts, such as the one in this thread (with less than 1.7% NSFW content).
So it's risky to speculate what percentage of NSFW content pages will trigger your account to be disabled. It's wise to prevent this so that you won't have to file an appeal for them to consider re-enabling your account.
One thing you might consider doing is installing keyword filters, as covered in their guidelines here (among the other steps listed there): What do I need to do to avoid having my account disabled?
Install keywords filters (such as adult content, pay-to services,
hacking content, gambling content, etc.), especially on pages
containing user-generated content. Although we're unable to provide
information on topic such as "keyword filtering" or "content
filtering", you may wish to search for this information on Google.