modelzoo.transformers.utils.attention_utils.SparseAttentionBuilder#

class modelzoo.transformers.utils.attention_utils.SparseAttentionBuilder[source]#

Bases: object

Methods

build_mask

get_pytorch_mask

__init__(num_heads, max_sequence_length, num_different_head_attn_configs=1)[source]#