I, female, managed to “survive” the physics barrier, it was rough. Intentionally so, I think. Years ago I had a female classmate majoring in chemistry, I believe, that changed her major to physics during her first year. She excelled at it, thrived, really.
i think it has far less to do with gender than just how your brain is wired. My husband and i are both lawyers, neither one of us was cut out for a scientific field. i was pre-med my first year of college, but i knew getting Cs wouldn’t get me into med school, so i switched. my brother is a ChemE and while no smarter than I am, he gutted his way through a year behind me. Maybe i could have scraped my way through in engineering, but it wasn’t what i was interested in. Though i have to say those i respected most of my law school classmates were those who were engineers, there were only a handful of them, but to be adept at language and math/sci is a bit more rare.