We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 07a7837 commit 6943babCopy full SHA for 6943bab
llama_cpp/_internals.py
@@ -42,6 +42,8 @@ def __init__(
42
43
self._llama_free_model = llama_cpp._lib.llama_free_model # type: ignore
44
45
+ self.model = None
46
+
47
if not os.path.exists(path_model):
48
raise ValueError(f"Model path does not exist: {path_model}")
49
@@ -248,6 +250,7 @@ def __init__(
248
250
self.verbose = verbose
249
251
252
self._llama_free = llama_cpp._lib.llama_free # type: ignore
253
+ self.ctx = None
254
255
assert self.model.model is not None
256
@@ -497,6 +500,7 @@ def __init__(
497
500
498
501
self._llama_batch_free = llama_cpp._lib.llama_batch_free # type: ignore
499
502
503
+ self.batch = None
504
self.batch = llama_cpp.llama_batch_init(
505
self.n_tokens, self.embd, self.n_seq_max
506
)
0 commit comments