我正在运行下面的代码来清理文本
import pandas as pd
def not_regex(pattern):
return r"((?!{}).)".format(pattern)
tmp = pd.DataFrame(['No one has a European accent either @',
'That the kid reminds me of Kevin'])
tmp[0].str.replace(not_regex('(\\b[-/]\\b|[a-zA-Z0-9])'), ' ')
然后它返回一个警告
<ipython-input-8-ef8a43f91dbd>:9: FutureWarning: The default value of regex will change from True to False in a future version.
tmp[0].str.replace(not_regex('(\\b[-/]\\b|[a-zA-Z0-9])'), ' ')
你能详细说明这一警告的原因吗?