Check with the vet, but one of my dogs did this for several months, and I had all kinds of tests done and she was fine. She would breathe so fast it was almost like she was on the verge of panting. She did a lot of that too. After I blew all the money on the tests, the vet summed it up:
"Molly is just a nervous nelly!"
It drove me nuts, she would pant forever after going out, even when it wasn't hot, and sound asleep would breathe like she was in terrible distress.
She breathes fast quite often even today at 6+. Even when she breathes normally, it's much deeper and faster than my other dog, King, her littermate. Her heart "pounds" too. I had that checked, too. Her only problems are bad hips and allergies.