We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 795600e commit 80b9c88Copy full SHA for 80b9c88
skops/io/_numpy.py
@@ -256,6 +256,17 @@ def _construct(self):
256
(np.random.RandomState, random_state_get_state),
257
(np.random.Generator, random_generator_get_state),
258
]
259
+
260
+try:
261
+ # From numpy=1.25.0 dispatching for `__array_function__` is done via
262
+ # a C wrapper: https://github.com/numpy/numpy/pull/23020
263
+ from numpy.core._multiarray_umath import _ArrayFunctionDispatcher
264
265
+ GET_STATE_DISPATCH_FUNCTIONS.append((_ArrayFunctionDispatcher, function_get_state))
266
+except ImportError:
267
+ pass
268
269
270
# tuples of type and function that creates the instance of that type
271
NODE_TYPE_MAPPING = {
272
("NdArrayNode", PROTOCOL): NdArrayNode,
0 commit comments