Instructions to use buetnlpbio/birna-bert with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use buetnlpbio/birna-bert with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("fill-mask", model="buetnlpbio/birna-bert", trust_remote_code=True)# Load model directly from transformers import AutoTokenizer, AutoModelForMaskedLM tokenizer = AutoTokenizer.from_pretrained("buetnlpbio/birna-bert", trust_remote_code=True) model = AutoModelForMaskedLM.from_pretrained("buetnlpbio/birna-bert", trust_remote_code=True) - Notebooks
- Google Colab
- Kaggle
Benchmarking issues
Running through this error when finetuning mrna-lncrna interaction prediciton code for rinalmo model.
Traceback (most recent call last):
File " BiRNA-BERT/example_code_and_data/mrna-lncrna/finetune.py", line 449, in
logits = model(input_ids_mirna, attention_mask_mirna, input_ids_lncrna, attention_mask_lncrna)
File " .local/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1775, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
File " .local/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1786, in _call_impl
return forward_call(*args, **kwargs)
File " BiRNA-BERT/example_code_and_data/mrna-lncrna/finetune.py", line 322, in forward
x = self.relu(self.fc1(x))
File " .local/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1775, in _wrapped_call_impl
return self._call_impl(*args, **kwargs)
File " .local/lib/python3.10/site-packages/torch/nn/modules/module.py", line 1786, in _call_impl
return forward_call(*args, **kwargs)
File " .local/lib/python3.10/site-packages/torch/nn/modules/linear.py", line 134, in forward
return F.linear(input, self.weight, self.bias)
RuntimeError: mat1 and mat2 shapes cannot be multiplied (32x326912 and 195840x1024)