castigate vs take one's medicine

castigate

verb
  • To punish or reprimand someone severely. 

  • To revise or make corrections to a publication. 

  • To execrate or condemn something in a harsh manner, especially by public criticism. 

take one's medicine

verb
  • To endure an unpleasant obligation, especially a punishment. 

  • Used other than figuratively or idiomatically: see take, medicine. 

How often have the words castigate and take one's medicine occurred in a corpus of books? (source: Google Ngram Viewer )