Skip to content

Commit 4832f42

Browse files
committed
PERF: use StringHashtable in data algos
xref pandas-dev#16107
1 parent 6ad32d2 commit 4832f42

File tree

1 file changed

+1
-4
lines changed

1 file changed

+1
-4
lines changed

pandas/core/algorithms.py

+1-4
Original file line numberDiff line numberDiff line change
@@ -216,10 +216,7 @@ def _get_data_algo(values, func_map):
216216

217217
# its cheaper to use a String Hash Table than Object
218218
if lib.infer_dtype(values) in ['string']:
219-
try:
220-
f = func_map['string']
221-
except KeyError:
222-
pass
219+
ndtype = 'string'
223220

224221
f = func_map.get(ndtype, func_map['object'])
225222

0 commit comments

Comments
 (0)