mirror of
https://github.com/ml-explore/mlx.git
synced 2025-11-08 13:28:15 +08:00
Support pickling array for bfloat16 (#2586)
* add bfloat16 pickling * Improvements * improve --------- Co-authored-by: Chen-Chen Yeh <ge96noj@mytum.de>
This commit is contained in:
@@ -12,6 +12,10 @@
|
||||
namespace mx = mlx::core;
|
||||
namespace nb = nanobind;
|
||||
|
||||
namespace nanobind {
|
||||
static constexpr dlpack::dtype bfloat16{4, 16, 1};
|
||||
}; // namespace nanobind
|
||||
|
||||
struct ArrayLike {
|
||||
ArrayLike(nb::object obj) : obj(obj) {};
|
||||
nb::object obj;
|
||||
|
||||
Reference in New Issue
Block a user