please read the poster's last post. my advice was given with what she wrote in it most explicitly in mind. as a professional teacher, I see these issues constantly and offered my advice directly from what she detailed about herself. From what the poster wrote, thankfully she already knows that emptying her head will not solve this issue. However, I constantly see students who labour under the misapprehension that because something SOMETIMES goes better when they don't think about it, the trick is to empty their mind or to think about something else. This is simply not true. The trick is to first understand the details better (so nothing is the result of guesswork or blind physical habit any more) and to then refine the conscious awareness down to just a few reference notes that trigger the rest. It's very hard to persuade some students. recently one told me how much better things worked when he didn't think BUT the results were not truly reliable at all. fortunately he was intelligent enough to pay heed when I explained the necessity to think more at first and wait until the habits had time to be properly acquired. he's made good progress at getting things more consistent. sadly, some students don't want to hear that, and persist on a track that never leads to reliability, simply because it sometimes goes right without understanding what is going on. sometimes isn't good enough for a high level.
Nowhere more than scales is it more important to have an absolutely rock solid mental picture before starting. Most mistakes are simply down to not visualising the whole octave as a single entity. when I play D flat major, b major or f sharp major, I literally never accidentally hit the wrong white key for thumb notes, as is so common. that's because I consciously map the whole scale out before playing a note. I have reliable physical habits for each one, but the physical habits are not going to guarantee that such minimal differences coupled with such overwhelmingly similarity will sort itself. you can't hope for your thumbs to know what it's your brains job to know. without the conscious brain actively mapping out the scale, it's a lottery. by doing a proper plan, it's almost as if the e natural doesn't exist to me in a d flat major scale. the f is so deeply ingrained in my thought that it's not possible to accidentally start depending on the physical habit from b major. the mental plan completely excludes any alternative physical habits from coming in and ensures that the only habits in play are those for the key of d flat major.
these things are just the very tip of the iceberg. another important ability is to be able to recite the notes of any scale and the fingers on them, away from the piano altogether. if you really understand the makeup of scales, it's easy to do for one hand. saying the fingering of a two handed scale is way harder, but should still be perfectly possible to do reliably, albeit with more thought. you should also be able to state the two thumb notes for either hand in any scale, with scarcely a moments thoughts. when you don't appreciate the construction well enough to have these things on the tip of your tongue at a moments notice, different habits inevitably get confused with other ones. when the brain is fully in charge, you can start refining it down to the smallest amount of conscious thought to play a scale. but it's never truly purely by rote. the fingers should never be trusted to sort out intricate and subtle differences between near identical movements. that's something that must be visualised clearly, via mental exercises.
By the time you've been through that last one of visualising every note and and every finger, the concentration involved is pouring water is positively mild by comparison. picturing how to do what I'm about to do at the piano is more than enough to get my concentration into gear, without any external distractions about pouring water.