I query some popular relays for a given pubkey, events after a specific date, limit 1. If the relays return 0 events, that's an inactive user.
Discussion
Ah.
How far back do you go?
How many “active users” are there?
I arbitrarily picked August 1 as the cutoff date. According to nostr.band, there are around 20,000 active users.