Skip to content

Commit 84b3f69

Browse files
authored
[Unity][SLM] GPU sampling (#16575)
This PR adds GPU sampling support to SLM
1 parent faa6628 commit 84b3f69

File tree

5 files changed

+973
-3
lines changed

5 files changed

+973
-3
lines changed

python/tvm/relax/frontend/nn/_tensor_op.py

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -67,6 +67,22 @@ def __truediv__(self, other):
6767
other = _convert_scalar(other, self)
6868
return _op().divide(self, other)
6969

70+
def __lt__(self, other):
71+
other = _convert_scalar(other, self)
72+
return _op().less(self, other)
73+
74+
def __le__(self, other):
75+
other = _convert_scalar(other, self)
76+
return _op().less_equal(self, other)
77+
78+
def __gt__(self, other):
79+
other = _convert_scalar(other, self)
80+
return _op().greater(self, other)
81+
82+
def __ge__(self, other):
83+
other = _convert_scalar(other, self)
84+
return _op().greater_equal(self, other)
85+
7086
def astype(self, dtype):
7187
return _op().astype(self, dtype)
7288

0 commit comments

Comments
 (0)