espnet2.legacy.nets.pytorch_backend.transducer.utils.subtract
Less than 1 minute
espnet2.legacy.nets.pytorch_backend.transducer.utils.subtract
espnet2.legacy.nets.pytorch_backend.transducer.utils.subtract(x: List[ExtendedHypothesis], subset: List[ExtendedHypothesis]) β List[ExtendedHypothesis]
Remove elements of subset if corresponding label ID sequence already exist in x.
- Parameters:
- x β Set of hypotheses.
- subset β Subset of x.
- Returns: New set of hypotheses.
- Return type: final
