You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/about/concepts/video/abstractions.md
+5-5Lines changed: 5 additions & 5 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -49,13 +49,11 @@ Each processing stage:
49
49
50
50
1. Inherits from `ProcessingStage`
51
51
2. Declares a stable `name` and `resources: Resources` (CPU cores, GPU memory, optional NVDEC/NVENC, or more than one GPU)
52
-
3. Defines `inputs()`/`outputs()` to document required attributes and produced attributes on tasks
52
+
3. Defines `inputs()`/`outputs()` to document that requires attributes or produces attributes on tasks
53
53
4. Implements `setup(worker_metadata)` for model initialization and `process(task)` to transform tasks
54
54
55
55
This design enables map-style execution with executor-managed fault tolerance and dynamic scaling per stage. Stages can optionally provide `process_batch()` to support vectorized batch processing.
56
56
57
-
Composite stages provide a user-facing convenience API and decompose into one or more execution stages at build time.
58
-
59
57
```python
60
58
classMyStage(ProcessingStage[X, Y]):
61
59
name: str="..."
@@ -68,6 +66,8 @@ class MyStage(ProcessingStage[X, Y]):
68
66
defprocess(self, task: X) -> Y | list[Y]: ...
69
67
```
70
68
69
+
Composite stages provide a user-facing convenience API and decompose into one or more execution stages at build time.
70
+
71
71
Refer to the stage base and resources definitions in Curator for full details.
72
72
73
73
### Resource Semantics
@@ -89,8 +89,8 @@ Video pipelines operate on task types defined in Curator:
89
89
-`Video`: Holds decoded metadata, frames, and lists of `Clip`
90
90
-`Clip`: Holds buffers, extracted frames, embeddings, and caption windows
91
91
92
-
Stages transform tasks stage by stage (for example, `VideoReader` populates `Video`, splitting stages create `Clip` objects, embedding and captioning stages annotate clips, and writer stages persist outputs).
92
+
Stages transform tasks stage by stage, and might run with different tasks on different stages (for example, `VideoReader` populates `Video`, splitting stages create `Clip` objects, embedding and captioning stages annotate clips, and writer stages persist outputs).
93
93
94
94
## Executors
95
95
96
-
Executors run pipelines on a backend. Curator uses [`XennaExecutor`](https://github.com/nvidia-cosmos/cosmos-xenna) to translate `ProcessingStage` definitions into Cosmos-Xenna stage specifications and run them on Ray with automatic scaling. Execution modes include streaming (default) and batch.
96
+
Executors run pipelines on a backend. Curator uses [`XennaExecutor`](https://github.com/nvidia-cosmos/cosmos-xenna) to translate `ProcessingStage` definitions into Cosmos-Xenna stage specifications and run them on Ray with automatic scaling. Execution modes include streaming (by default) and batch.
0 commit comments