def remove_define_emoji(desstr,restr=''): try: co = re.compile(u'😌') print 'remove define emoji only.' except Exception, e: print 'error ====' print e return co.sub(restr,desstr)