Yes, self selection as a response to perceived discrimination, or "lack of fit", is different from outright discrimination. But no less a problem, and certainly not unchangeable!
Would you settle for "close enough"? I would guess that Sweden is probably close enough. So, what's the fraction of CS students in Sweden who are female? If it's close to the fraction in the US, then the US is also probably "close enough" (in that specific way, by that measure).
Personal choice in a clearly gender egalitarian society is still personal choice.