ShardFilter (autotransform.filter.shard)
A base for sharding filters used by schedule runs to shard Input items.
- class autotransform.filter.shard.ShardFilter(*, inverted: bool = False, num_shards: int, valid_shard: int = -1)
Bases:
Filter
A base for sharding filters that checks that an Item fits the current valid shard.
- num_shards
The number of shards to split the items across.
- Type
int
- valid_shard
The current valid shard to use.
- Type
int
- num_shards: int
- valid_shard: int