Skip to content

Commit 9bee5b3

Browse files
authored
Fix (#10533)
1 parent 850c6c2 commit 9bee5b3

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

paddlenlp/transformers/token_dispatcher.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -52,7 +52,7 @@ def combine(self, hidden_states: paddle.Tensor) -> paddle.Tensor:
5252
pass
5353

5454
@abstractmethod
55-
def get_dispached_metadata(self) -> paddle.Tensor:
55+
def get_dispatched_metadata(self) -> paddle.Tensor:
5656
"""Get the metadata of the dispatched hidden_states."""
5757
pass
5858

@@ -154,7 +154,7 @@ def _indices_to_multihot(self, indices, probs):
154154
multihot_probs[row_indices, valid_indices] = probs[mask]
155155
return multihot_routing_map.cast(paddle.bool), multihot_probs
156156

157-
def get_dispached_metadata(self) -> paddle.Tensor:
157+
def get_dispatched_metadata(self) -> paddle.Tensor:
158158
return self.dispatched_indices, self.dispatched_probs
159159

160160
def get_number_of_tokens_per_expert(self) -> paddle.Tensor:

0 commit comments

Comments
 (0)