Instructions to use MohammadOthman/megatron-gpt2-classification with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use MohammadOthman/megatron-gpt2-classification with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="MohammadOthman/megatron-gpt2-classification")# Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("MohammadOthman/megatron-gpt2-classification") model = AutoModelForSequenceClassification.from_pretrained("MohammadOthman/megatron-gpt2-classification", device_map="auto") - Notebooks
- Google Colab
- Kaggle
| license: mit | |
| language: | |
| - en | |
| pipeline_tag: text-classification | |
| tags: | |
| - gpt2 | |
| - distributed-training | |
| - megatron | |
| - accelerate | |
| # Megatron-GPT2-Classification | |
| ## Description | |
| The `megatron-gpt2-classification` model is a language model trained using Megatron and Accelerate frameworks. It has been fine-tuned for classification tasks and benefits from distributed training across 4 GPUs (RTX 4070). | |
| ## Key Features | |
| - Trained with **Megatron** and **Accelerate**. | |
| - Distributed training on **4 GPUs (RTX 4070)**. | |
| - Fine-tuned for classification tasks. |