MCPcopy Create free account
hub / github.com/dmlc/xgboost / array_interface

Function array_interface

python-package/xgboost/_data_utils.py:514–518  ·  view source on GitHub ↗

Make array interface str.

(data: np.ndarray)

Source from the content-addressed store, hash-verified

512
513
514def array_interface(data: np.ndarray) -> bytes:
515 """Make array interface str."""
516 interface = array_interface_dict(data)
517 interface_str = bytes(json.dumps(interface), "utf-8")
518 return interface_str
519
520
521def check_cudf_meta(data: _CudaArrayLikeArg, field: str) -> None:

Callers 9

_ref_data_from_arrayMethod · 0.85
_ref_data_from_csrMethod · 0.85
inplace_predictMethod · 0.85
_grad_arrinfFunction · 0.85
_from_scipy_csrFunction · 0.85
_from_scipy_cscFunction · 0.85
_from_numpy_arrayFunction · 0.85
_meta_from_numpyFunction · 0.85
TESTFunction · 0.85

Calls 1

array_interface_dictFunction · 0.85

Tested by 1

TESTFunction · 0.68