← back to Exo
Make sure they're np arrays
9b66758b5936f6e1101a0345c0a56a26109d6587 · 2024-11-11 00:45:01 -0800 · Nel Nibcord
Files touched
M exo/inference/tinygrad/inference.py
Diff
commit 9b66758b5936f6e1101a0345c0a56a26109d6587
Author: Nel Nibcord <blindcrone@tuta.io>
Date: Mon Nov 11 00:45:01 2024 -0800
Make sure they're np arrays
---
exo/inference/tinygrad/inference.py | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/exo/inference/tinygrad/inference.py b/exo/inference/tinygrad/inference.py
index 3834ab1e..cd12eb91 100644
--- a/exo/inference/tinygrad/inference.py
+++ b/exo/inference/tinygrad/inference.py
@@ -75,7 +75,7 @@ class TinygradDynamicShardInferenceEngine(InferenceEngine):
async def encode(self, shard: Shard, prompt: str):
await self.ensure_shard(shard)
tokens = await asyncio.get_running_loop().run_in_executor(self.executor, self.tokenizer.encode, prompt)
- return tokens
+ return np.array(tokens)
async def decode(self, shard: Shard, tokens):
await self.ensure_shard(shard)
← b9d0fb68 Since infer_prompt is a thin wrapper that works the same for
·
back to Exo
·
Corrected type annotations c06b5f3b →