> For AI agents: the complete documentation index is available at /llms.txt, the full documentation bundle is available at /llms-full.txt.

# 加载训练数据集（LoadTrainingDataset）

<div class="node-meta"><code>LoadTrainingDataset</code><span>model/training</span><span>角色：条件编码</span></div>

此节点加载一个之前已保存到磁盘的编码训练数据集（latents 和 conditioning）。它会从 datasets 目录中所选的数据集文件夹读取所有 `shard_*.pkl` 数据分片文件，并返回合并后的 latent 向量和 conditioning 数据，供训练工作流使用。

## 参数

| 参数            | 类型    | 默认 / 范围      | 说明 |
| ------------- | ----- | ------------ | -- |
| `folder_name` | COMBO | 文件/选项（运行时列出） | —  |

## 输出

| 输出           | 类型           | 说明  |
| ------------ | ------------ | --- |
| latents      | LATENT       | 潜空间 |
| conditioning | CONDITIONING | 条件  |

## 怎么接

- **上游**：CLIP / CLIP_VISION / 编码模型
- **下游**：VAEDecode / 下一段采样
- **接线**：把 CLIP（或视觉/音频编码器）接到本节点，输出的 CONDITIONING 接 KSampler 的 `positive` 或 `negative`；条件在采样器之前还可以继续用条件修饰节点加工。

## 使用案例

属于「条件编码」类节点，向下游提供潜空间数据，通常进采样器或解码器。从 `folder_name`（文件/选项（运行时列出）） 开始填就能跑起来。典型接法：`CLIP` → 本节点 → `VAEDecode`。输出类型是 LATENT，只能接同类型的输入端口，颜色对不上就是接错了。

## 端口与连线示意

![LoadTrainingDataset 端口与连线示意](/svg/LoadTrainingDataset.svg)

## 同类节点

[绘制损失图](/nodes/01/LossGraphNode.md) · [制作训练数据集](/nodes/01/MakeTrainingDataset.md) · [分辨率 Bucket](/nodes/01/ResolutionBucket.md) · [保存训练数据集](/nodes/01/SaveTrainingDataset.md) · [训练 LoRA](/nodes/01/TrainLoraNode.md)
