Files
2026_DesignAI/officefile/appendix/tools.md
T
pengxiao 219232de74 refactor: 重组项目目录结构
以讲义内容为骨架迁移到标准目录格式:
- officefile/ 主内容(12章 + 附录 + CC4SI补充)
- dofile/ 代码示例(11个Python脚本)
- data/ 图片资源
- output/ 生成输出(忽略)
- Archive/ 归档旧目录(忽略)
- .claude/skills/ 保留markdown-to-docx工具链
- .pandoc/ 保留CSL和本地化配置

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
2026-05-25 14:00:56 +08:00

252 lines
4.6 KiB
Markdown
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
# 附录A:编程工具与资源
本附录整理AI学习和实践所需的编程工具、框架和资源。
---
## Python环境配置
### Anaconda/Miniconda
| 工具 | 大小 | 特点 | 下载地址 |
|-----|------|------|---------|
| Anaconda | ~500MB | 预装常用库 | [anaconda.com](https://www.anaconda.com/download) |
| Miniconda | ~50MB | 精简安装 | [docs.conda.io](https://docs.conda.io/en/latest/miniconda.html) |
### 安装步骤
```bash
# 1. 下载并安装Miniconda
# 2. 创建虚拟环境
conda create -n ai-env python=3.10
# 3. 激活环境
conda activate ai-env
# 4. 安装核心库
pip install torch torchvision numpy pandas scipy
```
---
## 深度学习框架
### PyTorch
```bash
pip install torch torchvision torchaudio
```
**特点**
- 动态计算图
- 研究友好
- 广泛的社区支持
**资源**
- [官方文档](https://pytorch.org/docs/)
- [中文教程](https://pytorch.zhangxiann.com/)
### TensorFlow
```bash
pip install tensorflow
```
**特点**
- 生产部署优化
- Keras高级API
- 跨平台支持
---
## 计算机视觉工具
### OpenCV
```bash
pip install opencv-python
```
**功能**:图像处理、视频分析
### Ultralytics YOLO
```bash
pip install ultralytics
```
**功能**:目标检测、实例分割
**使用示例**
```python
from ultralytics import YOLO
model = YOLO('yolov8n.pt')
results = model('image.jpg')
```
---
## AIGC工具链
### Stable Diffusion
**WebUI**[Automatic1111](https://github.com/AUTOMATIC1111/stable-diffusion-webui)
**ComfyUI**[GitHub](https://github.com/comfyanonymous/ComfyUI)
**API调用**
```python
from diffusers import StableDiffusionPipeline
pipe = StableDiffusionPipeline.from_pretrained("runwayml/stable-diffusion-v1-5")
image = pipe("a photo of an astronaut riding a horse on mars").images[0]
```
### ControlNet
```python
from diffusers import StableDiffusionControlNetPipeline
controlnet = ControlNetModel.from_pretrained("lllyasviel/sd-controlnet-canny")
pipe = StableDiffusionControlNetPipeline.from_pretrained("runwayml/stable-diffusion-v1-5", controlnet=controlnet)
```
### Midjourney
**平台**Discord
**文档**[docs.midjourney.com](https://docs.midjourney.com/)
---
## Agent开发框架
### LangChain
```bash
pip install langchain langchain-openai
```
**功能**LLM应用开发框架
**核心组件**
- ModelsLLM接口
- Prompts:提示管理
- Chains:链式调用
- Agents:智能体
- Memory:记忆管理
### LangGraph
```bash
pip install langgraph
```
**功能**:状态机式Agent开发
### LlamaIndex
```bash
pip install llama-index
```
**功能**:数据索引与检索(RAG
---
## 开发工具
### VSCode
**AI开发常用插件**
- Python
- Pylance
- Jupyter
- Copilot
### Cursor
**特点**AI原生IDE
**网址**[cursor.com](https://cursor.com/)
### Jupyter Lab
```bash
pip install jupyterlab
jupyter lab
```
---
## 在线学习资源
### 课程
| 名称 | 平台 | 链接 |
|-----|------|------|
| CS231n | Stanford | [cs231n.stanford.edu](http://cs231n.stanford.edu/) |
| Fast.ai | fast.ai | [course.fast.ai](https://course.fast.ai/) |
| 吴恩达深度学习 | Coursera | [coursera.org/specializations/deep-learning](https://www.coursera.org/specializations/deep-learning) |
### 博客与文档
- [Lil'Log](https://lilianweng.github.io/) - AI深度文章
- [The Illustrated Transformer](https://jalammar.github.io/illustrated-transformer/)
- [Distill.pub](https://distill.pub/) - 可视化论文
### 数据集
| 数据集 | 内容 | 链接 |
|-------|------|------|
| ImageNet | 图像分类 | [image-net.org](https://www.image-net.org/) |
| COCO | 目标检测 | [cocodataset.org](https://cocodataset.org/) |
| OpenStreetMap | 地图数据 | [openstreetmap.org](https://www.openstreetmap.org/) |
---
## 模型资源
### Hugging Face
**网址**[huggingface.co](https://huggingface.co/)
**功能**
- 模型仓库
- 数据集
- Spaces在线演示
### 常用模型
| 任务 | 推荐模型 | Hugging Face ID |
|-----|---------|----------------|
| 文生图 | Stable Diffusion XL | stabilityai/stable-diffusion-xl-base-1.0 |
| 目标检测 | YOLOv8 | Ultralytics |
| 语义分割 | SAM | segment-anything |
| 大语言模型 | Llama 3 | meta-llama/Meta-Llama-3-8B |
---
## 硬件资源
### 云平台
| 平台 | 特点 | 适合场景 |
|-----|------|---------|
| Google Colab | 免费GPU | 学习实验 |
| Kaggle Notebooks | 免费GPU | 竞赛 |
| AutoDL | 按时计费 | 中期项目 |
| 阿里云PAI | 国内稳定 | 生产部署 |
### 本地GPU
推荐配置:
- GPURTX 3060 (12GB) 或更高
- 内存:16GB+
- 存储:至少100GB SSD
---
## 最后更新
2026年4月