llm_benchmark


Namellm_benchmark JSON
Version 0.3.1 PyPI version JSON
download
home_pagehttps://github.com/aidatatools/ollama-benchmark/
SummaryLLM Benchmark for Throughputs via Ollama
upload_time2024-03-30 21:47:35
maintainerNone
docs_urlNone
authorJason Chuang
requires_python<4.0,>=3.8
licenseMIT
keywords benchmark llama ollama llms local
VCS
bugtrack_url
requirements No requirements were recorded.
Travis-CI No Travis.
coveralls test coverage No coveralls.
            # ollama-benchmark

LLM Benchmark for Throughput via Ollama (Local LLMs)

## Installation Steps

```bash
pip3 install ollama-benchmark
```

It's tested on Python 3.9 and above.

## ollama installation with the following models installed

7B model can be run on machines with 8GB of RAM

13B model can be run on machines with 16GB of RAM

## Usage explaination

On Windows, Linux, and macOS, it will detect memory RAM size to first download required LLM models.

When memory RAM size is greater than or equal to 4GB, but less than 7GB, it will check if gemma:2b exist. The program implicitly pull the model.

```bash
ollama pull gemma:2b
```

When memory RAM size is greater than 7GB, but less than 15GB, it will check if these models exist. The program implicitly pull these models

```bash
ollama pull gemma:2b
ollama pull gemma:7b
ollama pull mistral:7b
ollama pull llama2:7b
ollama pull llava:7b
```

When memory RAM siz is greater than 15GB, it will check if these models exist. The program implicitly pull these models

```bash
ollama pull gemma:2b
ollama pull gemma:7b
ollama pull mistral:7b
ollama pull llama2:7b
ollama pull llama2:13b
ollama pull llava:7b
ollama pull llava:13b
```

## Usage for general users directly

```bash
pip install llm-benchmark
llm_benchmark hello jason
llm_benchmark run
```

## Python Poetry manually(advanced) installation

<https://python-poetry.org/docs/#installing-manually>

## For developers to develop new features on Windows Powershell or on Ubuntu Linux or macOS

```bash
python3 -m venv .venv
. ./.venv/bin/activate
pip install -U pip setuptools
pip install poetry
```

## Usage in Python virtual environment

```bash
poetry shell
poetry install
llm_benchmark hello jason
```

### The default sending back the info is

Memory Size: 32GB

CPU: Intel i5-12400

GPU: 3060

OS: Microsoft Windows 11

### Example #1 send systeminfo and bechmark results to a remote server

```bash
llm_benchmark run
```

### Example #2 Do not send systeminfo and bechmark results to a remote server

```bash
llm_benchmark run --no-sendinfo
```

## Reference

[Ollama](https://ollama.com)

            

Raw data

            {
    "_id": null,
    "home_page": "https://github.com/aidatatools/ollama-benchmark/",
    "name": "llm_benchmark",
    "maintainer": null,
    "docs_url": null,
    "requires_python": "<4.0,>=3.8",
    "maintainer_email": null,
    "keywords": "benchmark, llama, ollama, llms, local",
    "author": "Jason Chuang",
    "author_email": "chuangtcee@gmail.com",
    "download_url": "https://files.pythonhosted.org/packages/77/01/bb5cd16986ee940cbdcc0241d4f1026e3948a337f1fce32ad5f1d75feea9/llm_benchmark-0.3.1.tar.gz",
    "platform": null,
    "description": "# ollama-benchmark\n\nLLM Benchmark for Throughput via Ollama (Local LLMs)\n\n## Installation Steps\n\n```bash\npip3 install ollama-benchmark\n```\n\nIt's tested on Python 3.9 and above.\n\n## ollama installation with the following models installed\n\n7B model can be run on machines with 8GB of RAM\n\n13B model can be run on machines with 16GB of RAM\n\n## Usage explaination\n\nOn Windows, Linux, and macOS, it will detect memory RAM size to first download required LLM models.\n\nWhen memory RAM size is greater than or equal to 4GB, but less than 7GB, it will check if gemma:2b exist. The program implicitly pull the model.\n\n```bash\nollama pull gemma:2b\n```\n\nWhen memory RAM size is greater than 7GB, but less than 15GB, it will check if these models exist. The program implicitly pull these models\n\n```bash\nollama pull gemma:2b\nollama pull gemma:7b\nollama pull mistral:7b\nollama pull llama2:7b\nollama pull llava:7b\n```\n\nWhen memory RAM siz is greater than 15GB, it will check if these models exist. The program implicitly pull these models\n\n```bash\nollama pull gemma:2b\nollama pull gemma:7b\nollama pull mistral:7b\nollama pull llama2:7b\nollama pull llama2:13b\nollama pull llava:7b\nollama pull llava:13b\n```\n\n## Usage for general users directly\n\n```bash\npip install llm-benchmark\nllm_benchmark hello jason\nllm_benchmark run\n```\n\n## Python Poetry manually(advanced) installation\n\n<https://python-poetry.org/docs/#installing-manually>\n\n## For developers to develop new features on Windows Powershell or on Ubuntu Linux or macOS\n\n```bash\npython3 -m venv .venv\n. ./.venv/bin/activate\npip install -U pip setuptools\npip install poetry\n```\n\n## Usage in Python virtual environment\n\n```bash\npoetry shell\npoetry install\nllm_benchmark hello jason\n```\n\n### The default sending back the info is\n\nMemory Size: 32GB\n\nCPU: Intel i5-12400\n\nGPU: 3060\n\nOS: Microsoft Windows 11\n\n### Example #1 send systeminfo and bechmark results to a remote server\n\n```bash\nllm_benchmark run\n```\n\n### Example #2 Do not send systeminfo and bechmark results to a remote server\n\n```bash\nllm_benchmark run --no-sendinfo\n```\n\n## Reference\n\n[Ollama](https://ollama.com)\n",
    "bugtrack_url": null,
    "license": "MIT",
    "summary": "LLM Benchmark for Throughputs via Ollama",
    "version": "0.3.1",
    "project_urls": {
        "Homepage": "https://github.com/aidatatools/ollama-benchmark/"
    },
    "split_keywords": [
        "benchmark",
        " llama",
        " ollama",
        " llms",
        " local"
    ],
    "urls": [
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "1b5273937774456f652901009385d4da965d8b584decd57b30a3397fb1b22dab",
                "md5": "1401ef629327d2d8164ac99aae49fcc7",
                "sha256": "051141b63b6776b63a7fa10477828147f0b55469a864f466a3b66a69d8d5d8d7"
            },
            "downloads": -1,
            "filename": "llm_benchmark-0.3.1-py3-none-any.whl",
            "has_sig": false,
            "md5_digest": "1401ef629327d2d8164ac99aae49fcc7",
            "packagetype": "bdist_wheel",
            "python_version": "py3",
            "requires_python": "<4.0,>=3.8",
            "size": 8953,
            "upload_time": "2024-03-30T21:47:33",
            "upload_time_iso_8601": "2024-03-30T21:47:33.501613Z",
            "url": "https://files.pythonhosted.org/packages/1b/52/73937774456f652901009385d4da965d8b584decd57b30a3397fb1b22dab/llm_benchmark-0.3.1-py3-none-any.whl",
            "yanked": false,
            "yanked_reason": null
        },
        {
            "comment_text": "",
            "digests": {
                "blake2b_256": "7701bb5cd16986ee940cbdcc0241d4f1026e3948a337f1fce32ad5f1d75feea9",
                "md5": "cbd5aad29d34e98cf88f36d8243c8d87",
                "sha256": "18838c0be8bf362f00aa98ffb14b90a63cde5c156207a608bacd384c216fac1f"
            },
            "downloads": -1,
            "filename": "llm_benchmark-0.3.1.tar.gz",
            "has_sig": false,
            "md5_digest": "cbd5aad29d34e98cf88f36d8243c8d87",
            "packagetype": "sdist",
            "python_version": "source",
            "requires_python": "<4.0,>=3.8",
            "size": 6449,
            "upload_time": "2024-03-30T21:47:35",
            "upload_time_iso_8601": "2024-03-30T21:47:35.592890Z",
            "url": "https://files.pythonhosted.org/packages/77/01/bb5cd16986ee940cbdcc0241d4f1026e3948a337f1fce32ad5f1d75feea9/llm_benchmark-0.3.1.tar.gz",
            "yanked": false,
            "yanked_reason": null
        }
    ],
    "upload_time": "2024-03-30 21:47:35",
    "github": true,
    "gitlab": false,
    "bitbucket": false,
    "codeberg": false,
    "github_user": "aidatatools",
    "github_project": "ollama-benchmark",
    "travis_ci": false,
    "coveralls": false,
    "github_actions": true,
    "requirements": [],
    "lcname": "llm_benchmark"
}
        
Elapsed time: 0.25382s