95 days since my surgery (3 months)
They do warn you before surgery that depression is a very common result of having open heart surgery. I mean - this is a very serious and scary thing. I was scared, anxious, nervous. 
One thing that I think helped me is that I am a pretty positive and optimistic person, and I believe that God has His hand on my life and all will be well.
I did have nurses and others comment on my positive attitude, and contrast it with other patients in my same situation.  But I also had an elective CABG - so I did not come in through the emergency room after a cardiac event, and I was relatively healthy heading into surgery. That is certainly going to make a difference. 
I also had a Dad who - despite many of his own hardships and significant health issues - always stayed positive, maintained a great sense of humor, and would point out that someone else always has it worse. We need to stay strong, positive and thankful.  I channeled a LOT of my Dad's positivity during all of this. I could feel his and my Mom's spirit with me, for sure. 

But I am also someone who is a bit "lit from within" and I believe in letting my light shine in the world. So I do try to stay optimistic and see the good side of things. I have seen people who are more 'negatively-wired' have a hard time with even small disruptions in their life, so if you are indeed that way, this will probably be a harder journey for you.  I do believe attitude, resilience and grit play a key role. But the good news is that we can all work on those things and get better at them.
I will also say that I did have a couple of episodes of sadness -- like a ton of bricks, it suddenly hit me one night that I had just had open heart surgery. I started to cry and was scared and anxious. I started praying to my parents and to God and it was really a bit of a 'stream of consciousness' of all the things I was feeling and afraid of while I cried. It felt good to let it all out, to be honest. But it surprised me because I thought I was doing pretty good mentally and emotionally and wasn't sure what that came from.
I am also a person of faith.  When I pray I do believe my prayers are heard. I also believe my parents, friends and loved ones who have died are all still connected to me and that they are praying for me and supporting me as well. As a Catholic, we call this the 'community of saints.' We are all connected, and remain connected. My ability to talk with God, and my family, and the saints, and just know in my soul that I was not alone was a great comfort to me. 
I spent a lot of time praying for everybody else.
I don't know how atheism works, or how someone would cope if they felt they were all alone. But I spent most of my time in the hospital praying for other people who were also in the hospital. I prayed for the surgeons and the nurses, the hospital staff, the patients and their families. 
I prayed for anyone who was in the emergency room that night, and anyone who had surgery. I prayed for the people who had surgery right after me, and everyone who had been in my room before me. I also prayed for the people who would be in my room next, and the people who didn't know they would be in my same position soon. I prayed for the people who were going to die that day, and their families. I prayed for the chaplains who would counsel them.
I prayed for my husband and my brothers and my family and asked God to keep them strong through all of this. And I prayed for all the people who felt alone, and sad, and frightened and asked God to wrap them in his love and mercy. And I prayed for the atheists - anyone who didn't know God and didn't know just how loved they were by Him. From saying rosaries to just random conversations with God, I felt better when I was praying for everyone else and asking Him to care for them. 
So if you're facing sadness or depression, maybe start praying for everyone else in the world who has it worse than you and ask God to help them through. Seems like it helps.