Code Monkey home page Code Monkey logo

llamaindex-rag-linux-cuda's People

Contributors

marklysze avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar

Forkers

huqy monoboard1

llamaindex-rag-linux-cuda's Issues

Error when run LlamaIndex_Mistral7B-RAG.ipynb in Jupyter Notebook.

According to README file https://github.com/marklysze/LlamaIndex-RAG-Linux-CUDA/blob/main/README.md

When I install from environment files and activate conda.

conda env create -f environment.yml
conda activate LlamaIndexRAGLinux

I install Jupyter Notebook and run.

pip install pip install  notebook ipykernel
jupyter-notebook --allow-root --no-browser --ip=0.0.0.0 --port=27000 --NotebookApp.token='1a4c347ef...........'

Then I run LlamaIndex_Mistral7B-RAG.ipynb in Jupyter Notebook. I select Kernel from Preferred Session (LlamaIndex_Mistral7B-RAG.ipynb)

When I run Code in Notebook at step 3

import torch

from llama_index.llms import LlamaCPP
from llama_index.llms.llama_utils import messages_to_prompt, completion_to_prompt
llm = LlamaCPP(
    model_url=None, # We'll load locally.
    model_path='./Models/mistral-7b-instruct-v0.1.Q6_K.gguf', # 6-bit model
    temperature=0.1,
    max_new_tokens=1024, # Increasing to support longer responses
    context_window=8192, # Mistral7B has an 8K context-window
    generate_kwargs={},
    # set to at least 1 to use GPU
    model_kwargs={"n_gpu_layers": 33}, # 33 was all that was needed for this and that fit with the RTX 3090's 24GB of memory
    messages_to_prompt=messages_to_prompt,
    completion_to_prompt=completion_to_prompt,
    verbose=True
)

It show error output.

ImportError                               Traceback (most recent call last)
Cell In[3], line 1
----> 1 import torch
      3 from llama_index.llms import LlamaCPP
      4 from llama_index.llms.llama_utils import messages_to_prompt, completion_to_prompt

File ~/anaconda3/envs/LlamaIndexRAGLinux/lib/python3.12/site-packages/torch/__init__.py:235
    233     if USE_GLOBAL_DEPS:
    234         _load_global_deps()
--> 235     from torch._C import *  # noqa: F403
    237 # Appease the type checker; ordinarily this binding is inserted by the
    238 # torch._C module initialization code in C
    239 if TYPE_CHECKING:

ImportError: /home/devteam/anaconda3/envs/LlamaIndexRAGLinux/lib/python3.12/site-packages/torch/lib/../../../../libcusparse.so.12: symbol __nvJitLinkGetLinkedCubin_12_2 version libnvJitLink.so.12 not defined in file libnvJitLink.so.12 with link time reference


Please advise how to solve this error, Thank you.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.