[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"similar-srush--annotated-s4":3,"tool-srush--annotated-s4":64},[4,17,27,35,43,56],{"id":5,"name":6,"github_repo":7,"description_zh":8,"stars":9,"difficulty_score":10,"last_commit_at":11,"category_tags":12,"status":16},3808,"stable-diffusion-webui","AUTOMATIC1111\u002Fstable-diffusion-webui","stable-diffusion-webui 是一个基于 Gradio 构建的网页版操作界面，旨在让用户能够轻松地在本地运行和使用强大的 Stable Diffusion 图像生成模型。它解决了原始模型依赖命令行、操作门槛高且功能分散的痛点，将复杂的 AI 绘图流程整合进一个直观易用的图形化平台。\n\n无论是希望快速上手的普通创作者、需要精细控制画面细节的设计师，还是想要深入探索模型潜力的开发者与研究人员，都能从中获益。其核心亮点在于极高的功能丰富度：不仅支持文生图、图生图、局部重绘（Inpainting）和外绘（Outpainting）等基础模式，还独创了注意力机制调整、提示词矩阵、负向提示词以及“高清修复”等高级功能。此外，它内置了 GFPGAN 和 CodeFormer 等人脸修复工具，支持多种神经网络放大算法，并允许用户通过插件系统无限扩展能力。即使是显存有限的设备，stable-diffusion-webui 也提供了相应的优化选项，让高质量的 AI 艺术创作变得触手可及。",162132,3,"2026-04-05T11:01:52",[13,14,15],"开发框架","图像","Agent","ready",{"id":18,"name":19,"github_repo":20,"description_zh":21,"stars":22,"difficulty_score":23,"last_commit_at":24,"category_tags":25,"status":16},1381,"everything-claude-code","affaan-m\u002Feverything-claude-code","everything-claude-code 是一套专为 AI 编程助手（如 Claude Code、Codex、Cursor 等）打造的高性能优化系统。它不仅仅是一组配置文件，而是一个经过长期实战打磨的完整框架，旨在解决 AI 代理在实际开发中面临的效率低下、记忆丢失、安全隐患及缺乏持续学习能力等核心痛点。\n\n通过引入技能模块化、直觉增强、记忆持久化机制以及内置的安全扫描功能，everything-claude-code 能显著提升 AI 在复杂任务中的表现，帮助开发者构建更稳定、更智能的生产级 AI 代理。其独特的“研究优先”开发理念和针对 Token 消耗的优化策略，使得模型响应更快、成本更低，同时有效防御潜在的攻击向量。\n\n这套工具特别适合软件开发者、AI 研究人员以及希望深度定制 AI 工作流的技术团队使用。无论您是在构建大型代码库，还是需要 AI 协助进行安全审计与自动化测试，everything-claude-code 都能提供强大的底层支持。作为一个曾荣获 Anthropic 黑客大奖的开源项目，它融合了多语言支持与丰富的实战钩子（hooks），让 AI 真正成长为懂上",140436,2,"2026-04-05T23:32:43",[13,15,26],"语言模型",{"id":28,"name":29,"github_repo":30,"description_zh":31,"stars":32,"difficulty_score":23,"last_commit_at":33,"category_tags":34,"status":16},2271,"ComfyUI","Comfy-Org\u002FComfyUI","ComfyUI 是一款功能强大且高度模块化的视觉 AI 引擎，专为设计和执行复杂的 Stable Diffusion 图像生成流程而打造。它摒弃了传统的代码编写模式，采用直观的节点式流程图界面，让用户通过连接不同的功能模块即可构建个性化的生成管线。\n\n这一设计巧妙解决了高级 AI 绘图工作流配置复杂、灵活性不足的痛点。用户无需具备编程背景，也能自由组合模型、调整参数并实时预览效果，轻松实现从基础文生图到多步骤高清修复等各类复杂任务。ComfyUI 拥有极佳的兼容性，不仅支持 Windows、macOS 和 Linux 全平台，还广泛适配 NVIDIA、AMD、Intel 及苹果 Silicon 等多种硬件架构，并率先支持 SDXL、Flux、SD3 等前沿模型。\n\n无论是希望深入探索算法潜力的研究人员和开发者，还是追求极致创作自由度的设计师与资深 AI 绘画爱好者，ComfyUI 都能提供强大的支持。其独特的模块化架构允许社区不断扩展新功能，使其成为当前最灵活、生态最丰富的开源扩散模型工具之一，帮助用户将创意高效转化为现实。",107662,"2026-04-03T11:11:01",[13,14,15],{"id":36,"name":37,"github_repo":38,"description_zh":39,"stars":40,"difficulty_score":23,"last_commit_at":41,"category_tags":42,"status":16},3704,"NextChat","ChatGPTNextWeb\u002FNextChat","NextChat 是一款轻量且极速的 AI 助手，旨在为用户提供流畅、跨平台的大模型交互体验。它完美解决了用户在多设备间切换时难以保持对话连续性，以及面对众多 AI 模型不知如何统一管理的痛点。无论是日常办公、学习辅助还是创意激发，NextChat 都能让用户随时随地通过网页、iOS、Android、Windows、MacOS 或 Linux 端无缝接入智能服务。\n\n这款工具非常适合普通用户、学生、职场人士以及需要私有化部署的企业团队使用。对于开发者而言，它也提供了便捷的自托管方案，支持一键部署到 Vercel 或 Zeabur 等平台。\n\nNextChat 的核心亮点在于其广泛的模型兼容性，原生支持 Claude、DeepSeek、GPT-4 及 Gemini Pro 等主流大模型，让用户在一个界面即可自由切换不同 AI 能力。此外，它还率先支持 MCP（Model Context Protocol）协议，增强了上下文处理能力。针对企业用户，NextChat 提供专业版解决方案，具备品牌定制、细粒度权限控制、内部知识库整合及安全审计等功能，满足公司对数据隐私和个性化管理的高标准要求。",87618,"2026-04-05T07:20:52",[13,26],{"id":44,"name":45,"github_repo":46,"description_zh":47,"stars":48,"difficulty_score":23,"last_commit_at":49,"category_tags":50,"status":16},2268,"ML-For-Beginners","microsoft\u002FML-For-Beginners","ML-For-Beginners 是由微软推出的一套系统化机器学习入门课程，旨在帮助零基础用户轻松掌握经典机器学习知识。这套课程将学习路径规划为 12 周，包含 26 节精炼课程和 52 道配套测验，内容涵盖从基础概念到实际应用的完整流程，有效解决了初学者面对庞大知识体系时无从下手、缺乏结构化指导的痛点。\n\n无论是希望转型的开发者、需要补充算法背景的研究人员，还是对人工智能充满好奇的普通爱好者，都能从中受益。课程不仅提供了清晰的理论讲解，还强调动手实践，让用户在循序渐进中建立扎实的技能基础。其独特的亮点在于强大的多语言支持，通过自动化机制提供了包括简体中文在内的 50 多种语言版本，极大地降低了全球不同背景用户的学习门槛。此外，项目采用开源协作模式，社区活跃且内容持续更新，确保学习者能获取前沿且准确的技术资讯。如果你正寻找一条清晰、友好且专业的机器学习入门之路，ML-For-Beginners 将是理想的起点。",84991,"2026-04-05T10:45:23",[14,51,52,53,15,54,26,13,55],"数据工具","视频","插件","其他","音频",{"id":57,"name":58,"github_repo":59,"description_zh":60,"stars":61,"difficulty_score":10,"last_commit_at":62,"category_tags":63,"status":16},3128,"ragflow","infiniflow\u002Fragflow","RAGFlow 是一款领先的开源检索增强生成（RAG）引擎，旨在为大语言模型构建更精准、可靠的上下文层。它巧妙地将前沿的 RAG 技术与智能体（Agent）能力相结合，不仅支持从各类文档中高效提取知识，还能让模型基于这些知识进行逻辑推理和任务执行。\n\n在大模型应用中，幻觉问题和知识滞后是常见痛点。RAGFlow 通过深度解析复杂文档结构（如表格、图表及混合排版），显著提升了信息检索的准确度，从而有效减少模型“胡编乱造”的现象，确保回答既有据可依又具备时效性。其内置的智能体机制更进一步，使系统不仅能回答问题，还能自主规划步骤解决复杂问题。\n\n这款工具特别适合开发者、企业技术团队以及 AI 研究人员使用。无论是希望快速搭建私有知识库问答系统，还是致力于探索大模型在垂直领域落地的创新者，都能从中受益。RAGFlow 提供了可视化的工作流编排界面和灵活的 API 接口，既降低了非算法背景用户的上手门槛，也满足了专业开发者对系统深度定制的需求。作为基于 Apache 2.0 协议开源的项目，它正成为连接通用大模型与行业专有知识之间的重要桥梁。",77062,"2026-04-04T04:44:48",[15,14,13,26,54],{"id":65,"github_repo":66,"name":67,"description_en":68,"description_zh":69,"ai_summary_zh":69,"readme_en":70,"readme_zh":71,"quickstart_zh":72,"use_case_zh":73,"hero_image_url":74,"owner_login":75,"owner_name":76,"owner_avatar_url":77,"owner_bio":78,"owner_company":79,"owner_location":80,"owner_email":81,"owner_twitter":82,"owner_website":83,"owner_url":84,"languages":85,"stars":98,"forks":99,"last_commit_at":100,"license":101,"difficulty_score":10,"env_os":102,"env_gpu":103,"env_ram":104,"env_deps":105,"category_tags":118,"github_topics":119,"view_count":10,"oss_zip_url":121,"oss_zip_packed_at":121,"status":16,"created_at":122,"updated_at":123,"faqs":124,"releases":154},1255,"srush\u002Fannotated-s4","annotated-s4","Implementation of https:\u002F\u002Fsrush.github.io\u002Fannotated-s4","annotated-s4 是一个开源实现项目，基于一篇博客文章（https:\u002F\u002Fsrush.github.io\u002Fannotated-s4），旨在帮助用户理解和实践 S4（State Space Model）模型。S4 是一种用于处理序列数据的深度学习模型，特别适用于时间序列、图像和文本等任务。\n\n这个工具解决了传统序列建模方法在处理长序列时效率低、性能差的问题，通过引入状态空间模型，提升了模型在复杂任务中的表现。它提供了多种实验配置，如 MNIST 和 QuickDraw 的序列建模、MNIST 和 CIFAR-10 的分类任务，方便研究人员和开发者快速测试和比较不同模型结构的效果。\n\nannotated-s4 适合有一定深度学习基础的研究人员和开发者使用，尤其对希望探索新型序列建模方法的用户来说非常有用。其独特的技术亮点在于实现了高效的 S4 模型，并支持多种变体（如 S4D、DSS 等），同时提供了详细的训练脚本和参数配置，便于复现和优化实验结果。","\n* **[Link To The Blog Post](https:\u002F\u002Fsrush.github.io\u002Fannotated-s4)**\n\n\n\u003Ca href=\"https:\u002F\u002Fsrush.github.io\u002Fannotated-s4\">\u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fsrush_annotated-s4_readme_f9f7140df40b.png\">\u003C\u002Fa>\n\n\n\n## Experiments\n\n#### MNIST Sequence Modeling\n\n```bash\npython -m s4.train dataset=mnist layer=s4 train.epochs=100 train.bsz=128 model.d_model=128 model.layer.N=64\n```\n\nThe following command uses a larger model (5M params) and logs generated samples to wandb every epoch. It achieves 0.36 test NLL (0.52 bits per dimension), a state-of-the-art on this task.\n```bash\npython -m s4.train dataset=mnist layer=s4 train.epochs=100 train.bsz=50 train.lr=5e-3 train.lr_schedule=true model.d_model=512 model.n_layers=6 model.dropout=0.0 train.weight_decay=0.05 model.prenorm=true model.embedding=true wandb.mode=online train.sample=308 \n```\n\n#### QuickDraw Sequence Modeling\n\n```bash\n# Default arguments\npython -m s4.train dataset=quickdraw layer=s4 train.epochs=10 train.bsz=128 model.d_model=128 model.layer.N=64\n\n# \"Run in a day\" variant\npython -m s4.train dataset=quickdraw layer=s4 train.epochs=1 train.bsz=512 model.d_model=256 model.layer.N=64 model.dropout=0.05\n```\n\n#### MNIST Classification\n\n```bash\npython -m s4.train dataset=mnist-classification layer=s4 train.epochs=20 train.bsz=128 model.d_model=128 model.dropout=0.25 train.lr=5e-3 train.lr_schedule=true seed=1\n```\n\nGets \"best\" 99.55% accuracy after 20 epochs @ 17s\u002Fepoch on an A100\n\n#### CIFAR-10 Classification\n\n```\npython -m s4.train dataset=cifar-classification layer={s4,dss,s4d} train.epochs=100 train.bsz=50 model.n_layers=6 model.d_model=512 model.dropout=0.25 train.lr=5e-3 train.weight_decay=0.01 train.lr_schedule=true seed=1\n```\n\nS4 gets \"best\" 91.23% accuracy after 100 epochs @ 2m16s\u002Fepoch on an A100\n\nDSS gets \"best\" 89.31% accuracy after 100 epochs @ 1m41s\u002Fepoch on an A100\n\nS4D gets \"best\" 89.76% accuracy after 100 epochs @ 1m32s\u002Fepoch on an A100\n\nThe alternative S4D-Lin initialization performs slightly better with 90.98% accuracy.\n\n```\npython -m s4.train dataset=cifar-classification layer=s4d train.epochs=100 train.bsz=50 model.n_layers=6 model.d_model=512 model.dropout=0.25 train.lr=5e-3 train.weight_decay=0.01 train.lr_schedule=true seed=1 +model.layer.scaling=linear\n```\n\n\n---\n\n## Quickstart (Development)\n\nWe have two `requirements.txt` files that hold dependencies for the current project: one that is tailored to CPUs,\nthe other that installs for GPU.\n\n### CPU-Only (MacOS, Linux)\n\n```bash\n# Set up virtual\u002Fconda environment of your choosing & activate...\npip install -r requirements-cpu.txt\n\n# Set up pre-commit\npre-commit install\n```\n\n### GPU (CUDA > 11 & CUDNN > 8.2)\n\n```bash\n# Set up virtual\u002Fconda environment of your choosing & activate...\npip install -r requirements-gpu.txt\n\n# Set up pre-commit\npre-commit install\n```\n\n## Dependencies from Scratch\n\nIn case the above `requirements.txt` don't work, here are the commands used to download dependencies.\n\n### CPU-Only\n\n```bash\n# Set up virtual\u002Fconda environment of your choosing & activate... then install the following:\npip install --upgrade \"jax[cpu]\"\npip install flax\npip install torch torchvision torchaudio\n\n# Defaults\npip install black celluloid flake8 google-cloud-storage isort ipython matplotlib pre-commit seaborn tensorflow tqdm\n\n# Set up pre-commit\npre-commit install\n```\n\n### GPU (CUDA > 11, CUDNN > 8.2)\n\nNote - CUDNN > 8.2 is critical for compilation without warnings, and GPU w\u002F at least Turing architecture for full\nefficiency.\n\n```bash\n# Set up virtual\u002Fconda environment of your choosing & activate... then install the following:\npip install jax[cuda11_cudnn82] -f https:\u002F\u002Fstorage.googleapis.com\u002Fjax-releases\u002Fjax_releases.html\npip install flax\npip install torch==1.10.1+cpu torchvision==0.11.2+cpu torchaudio==0.10.1+cpu -f https:\u002F\u002Fdownload.pytorch.org\u002Fwhl\u002Fcpu\u002Ftorch_stable.html\n\n# Defaults\npip install black celluloid flake8 google-cloud-storage isort ipython matplotlib pre-commit seaborn tensorflow tqdm\n\n# Set up pre-commit\npre-commit install\n```\n","* **[博客文章链接](https:\u002F\u002Fsrush.github.io\u002Fannotated-s4)**\n\n\n\u003Ca href=\"https:\u002F\u002Fsrush.github.io\u002Fannotated-s4\">\u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fsrush_annotated-s4_readme_f9f7140df40b.png\">\u003C\u002Fa>\n\n\n\n## 实验\n\n#### MNIST 序列建模\n\n```bash\npython -m s4.train dataset=mnist layer=s4 train.epochs=100 train.bsz=128 model.d_model=128 model.layer.N=64\n```\n\n以下命令使用了一个更大的模型（500万参数），并在每轮训练后将生成的样本记录到 WandB。该模型在该任务上的测试 NLL 达到 0.36（每维 0.52 比特），为当前最优水平。\n```bash\npython -m s4.train dataset=mnist layer=s4 train.epochs=100 train.bsz=50 train.lr=5e-3 train.lr_schedule=true model.d_model=512 model.n_layers=6 model.dropout=0.0 train.weight_decay=0.05 model.prenorm=true model.embedding=true wandb.mode=online train.sample=308 \n```\n\n#### QuickDraw 序列建模\n\n```bash\n# 默认参数\npython -m s4.train dataset=quickdraw layer=s4 train.epochs=10 train.bsz=128 model.d_model=128 model.layer.N=64\n\n# “一天内完成”版本\npython -m s4.train dataset=quickdraw layer=s4 train.epochs=1 train.bsz=512 model.d_model=256 model.layer.N=64 model.dropout=0.05\n```\n\n#### MNIST 分类\n\n```bash\npython -m s4.train dataset=mnist-classification layer=s4 train.epochs=20 train.bsz=128 model.d_model=128 model.dropout=0.25 train.lr=5e-3 train.lr_schedule=true seed=1\n```\n\n在 A100 上以每 epoch 17 秒的速度运行 20 轮后，达到“最佳”的 99.55% 准确率。\n\n#### CIFAR-10 分类\n\n```\npython -m s4.train dataset=cifar-classification layer={s4,dss,s4d} train.epochs=100 train.bsz=50 model.n_layers=6 model.d_model=512 model.dropout=0.25 train.lr=5e-3 train.weight_decay=0.01 train.lr_schedule=true seed=1\n```\n\nS4 在 A100 上以每 epoch 2 分 16 秒的速度运行 100 轮后，达到“最佳”的 91.23% 准确率。\n\nDSS 在 A100 上以每 epoch 1 分 41 秒的速度运行 100 轮后，达到“最佳”的 89.31% 准确率。\n\nS4D 在 A100 上以每 epoch 1 分 32 秒的速度运行 100 轮后，达到“最佳”的 89.76% 准确率。\n\n而采用 S4D-Lin 初始化的变体表现略好，准确率达到 90.98%。\n\n```\npython -m s4.train dataset=cifar-classification layer=s4d train.epochs=100 train.bsz=50 model.n_layers=6 model.d_model=512 model.dropout=0.25 train.lr=5e-3 train.weight_decay=0.01 train.lr_schedule=true seed=1 +model.layer.scaling=linear\n```\n\n\n---\n\n## 快速入门（开发）\n\n我们有两个 `requirements.txt` 文件，分别包含当前项目的依赖：一个专为 CPU 环境设计，另一个则用于 GPU 环境。\n\n### 仅 CPU（MacOS、Linux）\n\n```bash\n# 设置您选择的虚拟\u002Fconda 环境并激活...\npip install -r requirements-cpu.txt\n\n# 设置 pre-commit\npre-commit install\n```\n\n### GPU（CUDA > 11 且 CUDNN > 8.2）\n\n```bash\n# 设置您选择的虚拟\u002Fconda 环境并激活...\npip install -r requirements-gpu.txt\n\n# 设置 pre-commit\npre-commit install\n```\n\n## 从头安装依赖\n\n如果上述 `requirements.txt` 文件无法正常工作，以下是手动下载依赖的命令。\n\n### 仅 CPU\n\n```bash\n# 设置您选择的虚拟\u002Fconda 环境并激活...然后安装以下内容：\npip install --upgrade \"jax[cpu]\"\npip install flax\npip install torch torchvision torchaudio\n\n# 默认安装\npip install black celluloid flake8 google-cloud-storage isort ipython matplotlib pre-commit seaborn tensorflow tqdm\n\n# 设置 pre-commit\npre-commit install\n```\n\n### GPU（CUDA > 11，CUDNN > 8.2）\n\n注意——CUDNN > 8.2 对于无警告编译至关重要，同时 GPU 至少需具备 Turing 架构才能实现最佳效率。\n\n```bash\n# 设置您选择的虚拟\u002Fconda 环境并激活...然后安装以下内容：\npip install jax[cuda11_cudnn82] -f https:\u002F\u002Fstorage.googleapis.com\u002Fjax-releases\u002Fjax_releases.html\npip install flax\npip install torch==1.10.1+cpu torchvision==0.11.2+cpu torchaudio==0.10.1+cpu -f https:\u002F\u002Fdownload.pytorch.org\u002Fwhl\u002Fcpu\u002Ftorch_stable.html\n\n# 默认安装\npip install black celluloid flake8 google-cloud-storage isort ipython matplotlib pre-commit seaborn tensorflow tqdm\n\n# 设置 pre-commit\npre-commit install\n```","# annotated-s4 快速上手指南\n\n## 环境准备\n\n### 系统要求\n\n- **操作系统**：支持 macOS 和 Linux\n- **GPU 支持**（可选）：\n  - CUDA 版本 > 11.0\n  - CUDNN 版本 > 8.2（推荐用于编译无警告）\n\n### 前置依赖\n\n- Python 3.x\n- 虚拟环境（推荐使用 `conda` 或 `venv`）\n- JAX、Flax、PyTorch、TensorFlow 等深度学习框架\n\n---\n\n## 安装步骤\n\n### CPU 环境安装（适用于 macOS \u002F Linux）\n\n```bash\n# 创建并激活虚拟环境（根据你的偏好选择 conda 或 venv）\npip install -r requirements-cpu.txt\n\n# 安装 pre-commit 工具\npre-commit install\n```\n\n如果 `requirements-cpu.txt` 安装失败，可以手动安装以下依赖：\n\n```bash\npip install --upgrade \"jax[cpu]\"\npip install flax\npip install torch torchvision torchaudio\n\n# 安装常用工具\npip install black celluloid flake8 google-cloud-storage isort ipython matplotlib pre-commit seaborn tensorflow tqdm\n\n# 安装 pre-commit\npre-commit install\n```\n\n### GPU 环境安装（CUDA > 11, CUDNN > 8.2）\n\n```bash\n# 创建并激活虚拟环境\npip install -r requirements-gpu.txt\n\n# 安装 pre-commit\npre-commit install\n```\n\n如需手动安装，可执行以下命令：\n\n```bash\npip install jax[cuda11_cudnn82] -f https:\u002F\u002Fstorage.googleapis.com\u002Fjax-releases\u002Fjax_releases.html\npip install flax\npip install torch==1.10.1+cpu torchvision==0.11.2+cpu torchaudio==0.10.1+cpu -f https:\u002F\u002Fdownload.pytorch.org\u002Fwhl\u002Fcpu\u002Ftorch_stable.html\n\n# 安装常用工具\npip install black celluloid flake8 google-cloud-storage isort ipython matplotlib pre-commit seaborn tensorflow tqdm\n\n# 安装 pre-commit\npre-commit install\n```\n\n> 📌 提示：国内用户建议使用镜像源加速安装，例如将 pip 源替换为 [https:\u002F\u002Fpypi.tuna.tsinghua.edu.cn\u002Fsimple](https:\u002F\u002Fpypi.tuna.tsinghua.edu.cn\u002Fsimple)。\n\n---\n\n## 基本使用\n\n### 示例 1：MNIST 序列建模（简单配置）\n\n```bash\npython -m s4.train dataset=mnist layer=s4 train.epochs=100 train.bsz=128 model.d_model=128 model.layer.N=64\n```\n\n### 示例 2：QuickDraw 序列建模（快速训练）\n\n```bash\npython -m s4.train dataset=quickdraw layer=s4 train.epochs=1 train.bsz=512 model.d_model=256 model.layer.N=64 model.dropout=0.05\n```\n\n### 示例 3：MNIST 分类任务（准确率高达 99.55%）\n\n```bash\npython -m s4.train dataset=mnist-classification layer=s4 train.epochs=20 train.bsz=128 model.d_model=128 model.dropout=0.25 train.lr=5e-3 train.lr_schedule=true seed=1\n```\n\n### 示例 4：CIFAR-10 分类任务（S4 模型）\n\n```bash\npython -m s4.train dataset=cifar-classification layer=s4 train.epochs=100 train.bsz=50 model.n_layers=6 model.d_model=512 model.dropout=0.25 train.lr=5e-3 train.weight_decay=0.01 train.lr_schedule=true seed=1\n```","某科研团队正在开发一个基于序列建模的图像识别系统，用于自动分析手写数字和简单图形，以支持教育领域的智能评测系统。他们需要一种高效、准确且易于训练的模型架构来处理大量数据。\n\n### 没有 annotated-s4 时\n\n- 传统 RNN 和 LSTM 在处理长序列时容易出现梯度消失或爆炸问题，导致模型训练不稳定。\n- 使用 Transformer 架构虽然效果不错，但计算资源消耗大，难以在有限硬件条件下快速迭代。\n- 现有模型在 MNIST 分类任务上的准确率难以突破 99% 大关，影响系统的实际应用效果。\n- 模型训练周期较长，尤其是在 CIFAR-10 这类复杂数据集上，难以满足项目进度要求。\n- 缺乏清晰的实现文档和可复现的实验配置，使得模型调优过程困难重重。\n\n### 使用 annotated-s4 后\n\n- S4 模型通过状态空间方法有效解决了长序列建模中的梯度问题，提升了训练稳定性。\n- 在相同硬件条件下，S4 模型在 MNIST 分类任务中达到了 99.55% 的高准确率，显著优于传统方法。\n- 在 CIFAR-10 上，S4 模型在 100 个 epoch 内达到 91.23% 的准确率，训练效率远超其他模型。\n- 提供了完整的训练脚本和参数配置，使研究人员能够快速复现实验并进行模型调优。\n- 配合 WandB 等工具，可以实时监控训练过程并生成可视化结果，极大提升了开发效率。\n\n使用 annotated-s4 显著提升了序列建模任务的性能与开发效率，为复杂图像识别系统提供了可靠的技术支撑。","https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fsrush_annotated-s4_f9f7140d.png","srush","Sasha Rush","https:\u002F\u002Foss.gittoolsai.com\u002Favatars\u002Fsrush_0d88b2d1.jpg","Cornell Tech \u002F Hugging Face","Cornell","New York","srush.research@gmail.com","srush_nlp","http:\u002F\u002Frush-nlp.com","https:\u002F\u002Fgithub.com\u002Fsrush",[86,90,94],{"name":87,"color":88,"percentage":89},"Python","#3572A5",65.5,{"name":91,"color":92,"percentage":93},"Jupyter Notebook","#DA5B0B",33.7,{"name":95,"color":96,"percentage":97},"Makefile","#427819",0.8,514,69,"2026-04-02T09:54:04","MIT","Linux, macOS","需要 NVIDIA GPU，CUDA 版本 > 11.0，CUDNN 版本 > 8.2，建议显存 8GB+","未说明",{"notes":106,"python":104,"dependencies":107},"支持 CPU 和 GPU 环境，GPU 需要 Turing 架构以上以获得最佳性能。首次运行可能需要下载约 5GB 的模型文件。",[108,109,110,111,112,113,114,115,116,117],"jax","flax","torch","tensorflow","matplotlib","pre-commit","black","flake8","isort","tqdm",[13],[120,108],"deep-learning",null,"2026-03-27T02:49:30.150509","2026-04-06T09:45:06.595800",[125,130,135,140,145,150],{"id":126,"question_zh":127,"answer_zh":128,"source_url":129},5715,"如何在训练过程中生成 MNIST 数字图像？","生成 MNIST 数字图像需要足够长的训练步骤。根据项目中的实现，建议至少训练约 4000 步。如果仅训练 50-100 步，模型可能无法正确生成图像。此外，确保使用正确的参数配置，例如 `python -m s4.train dataset=mnist layer=s4 train.epochs=100 train.bsz=128 model.d_model=128 model.layer.N=64`。","https:\u002F\u002Fgithub.com\u002Fsrush\u002Fannotated-s4\u002Fissues\u002F72",{"id":131,"question_zh":132,"answer_zh":133,"source_url":134},5716,"如何解决 DNN 库初始化失败的问题？","此问题可能是由于 CUDA 或 cuDNN 版本不兼容导致的。解决方案是升级 cuDNN 并重新安装相关依赖包。例如，可以使用以下环境配置：Ubuntu 20.04；CUDA 11.3；cuDNN 8.9.4.25-1+cuda11.8；jaxlib 0.4.16+cuda11.cudnn86；jax 0.4.16；Python 3.9。","https:\u002F\u002Fgithub.com\u002Fsrush\u002Fannotated-s4\u002Fissues\u002F75",{"id":136,"question_zh":137,"answer_zh":138,"source_url":139},5717,"如何进行音频数字生成？是否可以指定条件生成？","音频数字生成可以通过指定前缀长度来实现。例如，使用 `l_prefix=0` 表示无条件生成。若需条件生成（如指定数字和说话人 ID），可以在生成脚本中设置相应的参数。生成脚本位于 [generate.py](https:\u002F\u002Fgithub.com\u002FHazyResearch\u002Fstate-spaces\u002Fblob\u002Fmain\u002Fgenerate.py)。","https:\u002F\u002Fgithub.com\u002Fsrush\u002Fannotated-s4\u002Fissues\u002F67",{"id":141,"question_zh":142,"answer_zh":143,"source_url":144},5718,"为什么 reshape 函数没有参数？","reshape 函数在此处用于将数组转换为标量（即形状为 () 的张量）。例如，`np.array([1]).reshape().shape` 的结果为 `()`。该操作是为了展示非矩阵风格的代码写法，并不会改变数据本身，只是改变了其形状表示方式。","https:\u002F\u002Fgithub.com\u002Fsrush\u002Fannotated-s4\u002Fissues\u002F41",{"id":146,"question_zh":147,"answer_zh":148,"source_url":149},5719,"为何在代码中使用 conj() 函数？","在代码中使用 `conj()` 是为了对复数矩阵进行共轭操作，这在某些数学推导中是必要的。尽管原始公式未明确说明这一点，但这是为了保证计算的准确性与一致性。","https:\u002F\u002Fgithub.com\u002Fsrush\u002Fannotated-s4\u002Fissues\u002F74",{"id":151,"question_zh":152,"answer_zh":153,"source_url":129},5720,"如何处理输入归一化问题？","如果使用的是标量输入（而非嵌入向量），建议将输入归一化到 [0, 1] 范围内（黑色像素映射为 0），而不是 [-1, 1]。这样有助于提升模型性能并避免潜在的数值问题。",[155],{"id":156,"version":157,"summary_zh":121,"released_at":158},115033,"v1","2022-03-01T15:11:55"]