MCPcopy Create free account
hub / github.com/ml-explore/mlx / operator-

Function operator-

mlx/ops.cpp:2787–2789  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2785 a.shape(), a.dtype(), std::make_shared<Negative>(to_stream(s)), {a});
2786}
2787array operator-(const array& a) {
2788 return negative(a);
2789}
2790
2791array sign(const array& a, StreamOrDevice s /* = {} */) {
2792 return array(a.shape(), a.dtype(), std::make_shared<Sign>(to_stream(s)), {a});

Callers

nothing calls this directly

Calls 2

subtractFunction · 0.85
negativeFunction · 0.70

Tested by

no test coverage detected