{
  "schema_version": "1.0",
  "id": "T-2eab9d0633cd",
  "url": "https://gpuatlas.top/articles/T-2eab9d0633cd/",
  "title": "Llama 3.1 8B 本地跑起来，显存、内存和硬盘分别要多少？",
  "summary": "Llama 3.1 8B资源预算应固定具体版本和格式，分别记录完整文件、加载主存与长请求峰值。",
  "language": "zh-Hans",
  "category": {
    "id": "c-14",
    "name": "模型运行需求",
    "url": "https://gpuatlas.top/categories/c-14/"
  },
  "topics": [
    {
      "id": "model-c62822b7bd",
      "name": "Llama 3.1",
      "kind": "model",
      "description": "从 8B 等具体版本出发，检查不同显卡上的量化运行条件，随后再安排上下文与微调预算。",
      "url": "https://gpuatlas.top/topics/model-c62822b7bd/"
    }
  ],
  "body_text": "Llama 3.1 8B本地部署，先固定Base或Instruct和文件格式，再分别预算磁盘、主存与显存。按8B名义参数，16bit原始数据约16GB、理想4bit约4GB，实际参数、元数据和运行开销还需核对。\n\n磁盘按完整发布清单准备，权重、索引、配置和分词器都应匹配。自行转换时，原文件、中间结果与最终文件可能同时存在；保留多个精度也需要重复空间，不能只按成品大小安排。\n\n主存取决于加载、内存映射与CPU卸载方式。模型最终完整驻留GPU，也可能有启动暂存峰值；CPU混合运行则需要记录主存驻留、换页和完整等待。\n\n显存还需要缓存与工作缓冲。输入、历史和输出共同影响请求预算，官方128K能力不表示当前设备能够直接承担。权重小于显存，只说明有机会加载，尚未通过长文或并发验收。\n\nLlama 3.1 8B用于文档问答时，先把所选Base或Instruct的输入方式对齐，再运行最长日常材料。文件尚未加载就失败，检查磁盘清单和启动主存；读材料或生成答案时失败，再查缓存与显存峰值。资源调整应跟着失败阶段走，不能用另一个版本短题通过的结果替当前配置作保证。",
  "published_at": null,
  "modified_at": "2026-11-26T15:17:38.690397+00:00",
  "evidence": {
    "type": "documentation_and_conditional_estimates",
    "hardware_tested": false,
    "note": "资料解释与条件估算，非硬件实测。"
  },
  "sources": [
    {
      "id": "llama31-card",
      "url": "https://raw.githubusercontent.com/meta-llama/llama-models/main/models/llama3_1/MODEL_CARD.md",
      "retrieved_at": "2026-11-25T11:28:43.769677+00:00"
    },
    {
      "id": "hf-download",
      "url": "https://raw.githubusercontent.com/huggingface/huggingface_hub/main/docs/source/en/guides/download.md",
      "retrieved_at": "2026-11-25T10:24:21.873697+00:00"
    },
    {
      "id": "llamacpp-server",
      "url": "https://raw.githubusercontent.com/ggml-org/llama.cpp/master/tools/server/README.md",
      "retrieved_at": "2026-11-25T09:52:45.997121+00:00"
    },
    {
      "id": "vllm-memory",
      "url": "https://raw.githubusercontent.com/vllm-project/vllm/main/docs/configuration/conserving_memory.md",
      "retrieved_at": "2026-11-25T09:52:45.997121+00:00"
    }
  ],
  "revision_note": "完善阅读结构；非硬件实测。",
  "representations": {
    "html": "https://gpuatlas.top/articles/T-2eab9d0633cd/",
    "json": "https://gpuatlas.top/data/articles/T-2eab9d0633cd.json",
    "markdown": "https://gpuatlas.top/data/articles/T-2eab9d0633cd.md"
  }
}
