Skip to content

Commit

Permalink
[tokenizer] Fixes TextEmbeddingTranslator only uses CPU (#3122)
Browse files Browse the repository at this point in the history
  • Loading branch information
frankfliu authored Apr 24, 2024
1 parent a2f075f commit 6b7215c
Showing 1 changed file with 0 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -175,7 +175,6 @@ private NDArray processEmbedding(NDManager manager, NDList list, Encoding encodi
throw new AssertionError("Unexpected pooling mode: " + pooling);
}

embedding = embedding.toDevice(Device.cpu(), false);
if (denseModel != null) {
NDArray weight = denseModel.get("linear.weight");
NDArray bias = denseModel.get("linear.bias");
Expand Down

0 comments on commit 6b7215c

Please sign in to comment.