Panting is not good.
It’s usually a symptom of pain. Get to a vet and diagnose what is causing the pain, and hence the panting. In hot weather, a dog will pant when overheated. This is also something to be treated immediately. Please see our article on Heat Exhaustion.