Instructions to use igorktech/hibial-bert-i3-mlm-v0.1 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use igorktech/hibial-bert-i3-mlm-v0.1 with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("fill-mask", model="igorktech/hibial-bert-i3-mlm-v0.1", trust_remote_code=True)# Load model directly from transformers import AutoModelForMaskedLM model = AutoModelForMaskedLM.from_pretrained("igorktech/hibial-bert-i3-mlm-v0.1", trust_remote_code=True, dtype="auto") - Notebooks
- Google Colab
- Kaggle
Update modelling_hibial.py
Browse files- modelling_hibial.py +1 -3
modelling_hibial.py
CHANGED
|
@@ -333,9 +333,7 @@ class HiBiAlBert(Module):
|
|
| 333 |
|
| 334 |
bialibi_utt_mask[enc_mask_utt.bool()] = float('-inf')
|
| 335 |
bialibi_ct_mask[enc_mask_ct.bool()] = float('-inf')
|
| 336 |
-
|
| 337 |
-
src_key_padding_mask = torch.where(src_key_padding_mask, torch.tensor(float('-inf')), torch.tensor(0.0))
|
| 338 |
-
|
| 339 |
# memory = self.encoder(input_ids, mask=src_mask, src_key_padding_mask=src_key_padding_mask)
|
| 340 |
|
| 341 |
# Encoding
|
|
|
|
| 333 |
|
| 334 |
bialibi_utt_mask[enc_mask_utt.bool()] = float('-inf')
|
| 335 |
bialibi_ct_mask[enc_mask_ct.bool()] = float('-inf')
|
| 336 |
+
|
|
|
|
|
|
|
| 337 |
# memory = self.encoder(input_ids, mask=src_mask, src_key_padding_mask=src_key_padding_mask)
|
| 338 |
|
| 339 |
# Encoding
|