Medical Data Analyser - 2 errors

Try doing that (adding .fig at the end of your sns.catplot to effectively return a fig object).