def get_special_tokens_mask(tokenizer, labels):
    """ Returns a mask for special tokens that should be ignored for sampling during masked language modelling. """
    return list(map(lambda x: 1 if x in [tokenizer.sep_token_id, tokenizer.cls_token_id, tokenizer.pad_token_id] else 0,
                    labels))