ENH move utility function into dedicated file, not __init__.py