Buckets:
| # Pipeline 状态 | |
| ## PipelineState[[diffusers.modular_pipelines.PipelineState]] | |
| #### diffusers.modular_pipelines.PipelineState[[diffusers.modular_pipelines.PipelineState]] | |
| ```python | |
| diffusers.modular_pipelines.PipelineState(values: dict[str, typing.Any] = <factory>, kwargs_mapping: dict[str, list[str]] = <factory>) | |
| ``` | |
| [源代码](https://github.com/huggingface/diffusers/blob/v0.43.0/src/diffusers/modular_pipelines/modular_pipeline.py#L231) | |
| `PipelineState` 存储流水线的状态。它用于在流水线块之间传递数据。 | |
| #### get[[diffusers.modular_pipelines.PipelineState.get]] | |
| ```python | |
| get(keys: str | list[str], default: Any = None) | |
| ``` | |
| [源代码](https://github.com/huggingface/diffusers/blob/v0.43.0/src/diffusers/modular_pipelines/modular_pipeline.py#L256) | |
| **参数:** | |
| keys (str | list[str]) : 值对应的键或键列表 | |
| default (Any) : 未找到时返回的默认值 | |
| **返回:** Any | dict[str, Any] | |
| 如果 keys 是 str,则为单个值;如果 keys 是 list,则为值的字典 | |
| 从 pipeline 状态中获取一个或多个值。 | |
| #### get_by_kwargs[[diffusers.modular_pipelines.PipelineState.get_by_kwargs]] | |
| ```python | |
| get_by_kwargs(kwargs_type: str) | |
| ``` | |
| [源代码](https://github.com/huggingface/diffusers/blob/v0.43.0/src/diffusers/modular_pipelines/modular_pipeline.py#L271) | |
| **参数:** | |
| kwargs_type (str) : 用于过滤的 kwargs_type | |
| **返回:** dict[str, Any] | |
| 与 kwargs_type 匹配的值字典 | |
| 获取所有与 kwargs_type 匹配的值。 | |
| #### set[[diffusers.modular_pipelines.PipelineState.set]] | |
| ```python | |
| set(key: str, value: Any, kwargs_type: str = None) | |
| ``` | |
| [源代码](https://github.com/huggingface/diffusers/blob/v0.43.0/src/diffusers/modular_pipelines/modular_pipeline.py#L239) | |
| **参数:** | |
| key (str):值的键 | |
| value (任意):要存储的值 | |
| kwargs_type (str) : 与该值关联的 kwargs_type | |
| 向流水线状态添加一个值。 | |
| #### to_dict[[diffusers.modular_pipelines.PipelineState.to_dict]] | |
| ```python | |
| to_dict() | |
| ``` | |
| [源代码](https://github.com/huggingface/diffusers/blob/v0.43.0/src/diffusers/modular_pipelines/modular_pipeline.py#L284) | |
| 将 PipelineState 转换为字典。 | |
| ## BlockState[[diffusers.modular_pipelines.BlockState]] | |
| #### diffusers.modular_pipelines.BlockState[[diffusers.modular_pipelines.BlockState]] | |
| ```python | |
| diffusers.modular_pipelines.BlockState(**kwargs) | |
| ``` | |
| [源代码](https://github.com/huggingface/diffusers/blob/v0.43.0/src/diffusers/modular_pipelines/modular_pipeline.py#L321) | |
| 用于块状态数据的容器,支持属性访问和格式化表示。 | |
| #### as_dict[[diffusers.modular_pipelines.BlockState.as_dict]] | |
| ```python | |
| as_dict() | |
| ``` | |
| [源代码](https://github.com/huggingface/diffusers/blob/v0.43.0/src/diffusers/modular_pipelines/modular_pipeline.py#L338) | |
| **返回:** dict[str, Any] | |
| 包含 BlockState 所有属性的字典 | |
| 将 BlockState 转换为字典。 | |
Xet Storage Details
- Size:
- 2.89 kB
- Xet hash:
- aadf086e969b9849e4bd18efd0a9dd32d4be6ec193df2d6774ce9b2005840e23
·
Xet efficiently stores files, intelligently splitting them into unique chunks and accelerating uploads and downloads. More info.