cudf.core.column.string.StringMethods.normalize_spaces# StringMethods.normalize_spaces() → SeriesOrIndex[source]# 移除标记之间的多余空白,并从每个字符串的开头和结尾修剪空白。 Returns: Series or Index of object. 示例 >>> import cudf >>> ser = cudf.Series(["hello \\t world"," test string "]) >>> ser.str.normalize_spaces() 0 hello world 1 test string dtype: object