<commit_before># Author: <NAME>
# License: BSD
"""
Uses C++ map containers for fast dict-like behavior with keys being
integers, and values float.
"""

from libcpp.map cimport map as cpp_map

# Import the C-level symbols of numpy
cimport numpy as np

ctypedef np.float64_t DTYPE_t

ctypedef np.intp_t ITYPE_t

###############################################################################
# An object to be used in Python

cdef class IntFloatDict:
    cdef cpp_map[ITYPE_t, DTYPE_t] my_map
    cdef _to_arrays(self, ITYPE_t [:] keys, DTYPE_t [:] values)
<commit_msg>MNT Use cimport numpy as cnp in Cython files for NumPy C API for sklearn/utils/_fast_dict.pxd (#23301)<commit_after># Author: <NAME>
# License: BSD
"""
Uses C++ map containers for fast dict-like behavior with keys being
integers, and values float.
"""

from libcpp.map cimport map as cpp_map

# Import the C-level symbols of numpy
cimport numpy as cnp

ctypedef cnp.float64_t DTYPE_t

ctypedef cnp.intp_t ITYPE_t

###############################################################################
# An object to be used in Python

cdef class IntFloatDict:
    cdef cpp_map[ITYPE_t, DTYPE_t] my_map
    cdef _to_arrays(self, ITYPE_t [:] keys, DTYPE_t [:] values)

{'fraction_non_alphanumeric': 0.19902120717781402, 'fraction_numerical': 0.00734094616639478, 'mean_word_length': 5.165829145728643, 'pattern_counts': {'":': 0, '<': 5, '<?xml version=': 0, '>': 5, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3802164', 'n_tokens_mistral': 425, 'n_tokens_neox': 403, 'n_words': 139}