Instructions to use labhamlet/gramt-mono with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use labhamlet/gramt-mono with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("feature-extraction", model="labhamlet/gramt-mono", trust_remote_code=True)# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("labhamlet/gramt-mono", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
Update model.py
Browse files8 unmodified lines9101112131411 unmodified lines262728293031328 unmodified linesfrom einops import rearrangedef conv3x3(in_channels, out_channels, stride=1):"3x3 convolution with padding"11 unmodified linesdecoder_depth: int = 8,decoder_num_heads: int = 8,decoder_embedding_dim: int = 512,decoder_window_sizes: list[int] = [2, 5, 10, 25, 50, 100, 0, 0],encoder_num_layers = 12,encoder_num_heads = 12,encoder_hidden_dim = 768,8 unmodified lines910111213141511 unmodified lines272829303132338 unmodified linesfrom einops import rearrangefrom typing import Listdef conv3x3(in_channels, out_channels, stride=1):"3x3 convolution with padding"11 unmodified linesdecoder_depth: int = 8,decoder_num_heads: int = 8,decoder_embedding_dim: int = 512,decoder_window_sizes: List[int] = [2, 5, 10, 25, 50, 100, 0, 0],encoder_num_layers = 12,encoder_num_heads = 12,encoder_hidden_dim = 768,
model.py+2-1