Fix gguf not imported correctly
This commit is contained in:
parent
69729a34b5
commit
87509005a8
1 changed files with 3 additions and 1 deletions
|
@ -29,7 +29,9 @@ from typing import TYPE_CHECKING, Any, Callable, IO, Iterable, Literal, TypeVar,
|
||||||
import numpy as np
|
import numpy as np
|
||||||
|
|
||||||
if 'NO_LOCAL_GGUF' not in os.environ:
|
if 'NO_LOCAL_GGUF' not in os.environ:
|
||||||
sys.path.insert(1, str(Path(__file__).parent / 'gguf-py'))
|
# use .parent.parent since we are in "examples" directory
|
||||||
|
sys.path.insert(1, str(Path(__file__).parent.parent / 'gguf-py'))
|
||||||
|
|
||||||
import gguf
|
import gguf
|
||||||
from gguf import BaseVocab, Vocab, NoVocab, BpeVocab, SentencePieceVocab, LlamaHfVocab
|
from gguf import BaseVocab, Vocab, NoVocab, BpeVocab, SentencePieceVocab, LlamaHfVocab
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue