How to Map Column with Dictionary in Pandas

NameError: name 'nan' is not defined in Pandas and Python