I can tell you are a good man...you deserve a good life.
i am guessing there are many reasons can contribute to your wife's "bad mood"....postpartum depression, sleep deprivation (both kids sleep with her...assuming the kids are not good sleepers), sense of insecurity or lack the sense of accomplishment (Ph.D without a job). Perhaps you are her only target to relief her stress. However, she unconciously made a huge mistake. The detriorating relationship with you only made the situation even worse.
After many years of ups and downs, I finally realized how important it is to know what exactly you want in your life, from your relationship with others. Knowing what you want helps you to appreciate what you have today, the people in your life. Life is good!