Swimmer Missy Franklin stole the show at the 2012 Olympic Games in London, winning four gold medals in her debut as an Olympic-level competitive swimmer. And she showed up to the Olympic Games in Rio de Janeiro, ready to make 2016 her year. But things didn't go as she'd hoped. Franklin struggled to qualify for events she'd previously set records in, and she experienced panic attacks for the first time in her life. Franklin’s opening up about these panic attacks in her new memoir, Relentless Spirit: The Unconventional Raising Of A Champion.

"I could tell [something was off] at trials," Franklin writes in her memoir (excerpted by TIME). "Everyone could tell, looking back, but when I was down there in that pool, struggling to find my rhythm, my mojo, I could tell most of all." Franklin explains that she was experiencing panic attacks—a form of anxiety she'd never encountered before. "My throat would close, I couldn’t breathe, and I’d start to shake uncontrollably," she writes. "I couldn’t explain it, couldn’t understand it—but there it was. And all I could think was, 'What is happening? This isn’t me. This isn’t me.'"

Amanda Itzkoff, M.D., psychiatrist at Manhattan Psychiatry, tells SELF that many people experience panic attacks at some point in their lives. They usually consist of some combination of the following symptoms: intense feelings of fear, sweating, trembling, nausea, chest pain, the need to use the restroom, heart palpitations or pounding, difficulty breathing, dizziness, chills, being overheated, and numbness in the hands.

"Patients often describe being afraid they're going to die or feeling like they're 'going crazy,'" Itzkoff says. "They feel like they might get 'stuck' like this."

Panic attack symptoms come on suddenly and last for a period of minutes before going away—which is how you can differentiate them from ordinary feelings of stress or anxiety, she says.

Panic attacks are different from panic disorder, which impacts 6 million people in the US. Whereas panic attack symptoms come and go fairly quickly, panic disorder involves a person feeling consistently afraid or worried that they'll experience another panic attack. "That worry can sometimes be worse, because the worry can last much longer," Sumati Gupta, Ph.D., clinical psychologist at Tribeca Psychology, tells SELF. "You can be worried multiple times a day that you'll have a panic attack in the office, even if you've only had one panic attack in the last month."

In her essay, Franklin writes about coping with her anxiety by meditating with her trainer. This is one of many treatment options available to people dealing with panic attacks or panic disorder. Gupta says that medication prescribed by a doctor can help in the short-term, but the general long-term treatment of choice within the psychology community is something called cognitive behavior therapy (CBT). During the first part of CBT, the patient learns what panic attacks and panic disorder generally involve and how they specifically affect them. From there, the psychologist will engage in what's called interoceptive awareness. The psychologist will induce one of the common panic attack symptoms the patient tends to experience (sweating, for example) and teach them how to respond to that symptom in a way that doesn't escalate their anxiety.

"The idea is that it's part of what's happening in a panic attack," Gupta says. "Yes, you're having a real symptom. But it's your mental response to it that matters." This treatment typically lasts several weeks or several months, and Gupta says a significant amount of empirical research has proven these methods effective.

It’s unclear how Franklin is treating her panic attacks, but Itzkoff says this CBT approach could be particularly helpful to athletes. Athletes typically experience isolated panic attack symptoms (pounding heart, shortness of breath) just from competing in their sport. By exposing the athletes to these sensations in a safe environment, they can understand what they're experiencing and respond in a way that won't bring on a debilitating panic attack.

In her memoir, Franklin writes that she’s not going to let panic attacks, or her disappointment in Rio, hold her back: "Everyone knows what it’s like to fail—and here I’d failed in front of billions of people. I’m determined to rediscover the joy of swimming that helped me to win all those medals in London, putting up times that still stand as world records, Olympic records. I don’t feel that joy right now, but I know it’s in me. Deep down. Somewhere. I need only to tap back into it, embrace it, make it once again my own.”