How to Run
Language & Framework
- Language: Python
- Framework: PyTorch
Installation
Make sure you have Python installed, then run the following commands to set up the environment:
## Installation
To install the package without ML dependencies:
pip install sagar-neuron-gpt2
Then you should install
pip install torch
pip install tiktoken
pip install numpy
To include ML dependencies (torch and tiktoken):
pip install sagar-neuron-gpt2[ml]
pip install numpy
Train the Model
To train and save your GPT-2 model weights, run the following:
from sagar_nueron_gpt2.TrainAndSaveGptWeights import Execute
exe = Execute()
exe.execute()
Inference from Trained Model
To run inference using the model you trained:
from sagar_nueron_gpt2.inference_model import Inferencing
exe = Inferencing()
exe.inference()
Metadata
Release files for sagar-neuron-gpt2 0.1.9
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| sagar_neuron_gpt2-0.1.9.tar.gz | 797.6 kB | Without provenance | Details for sagar_neuron_gpt2-0.1.9.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| sagar_neuron_gpt2-0.1.9-py3-none-any.whl | Python 3 | none | any | Details for sagar_neuron_gpt2-0.1.9-py3-none-any.whl |
Total release size: 992.7 kB
Release files / sagar_neuron_gpt2-0.1.9.tar.gz
| Download URL | sagar_neuron_gpt2-0.1.9.tar.gz |
|---|---|
| Size | 797.6 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
1f584d958edc69227adc46907777bb349f413103378dd2c8b243076de9bc0e83
|
|
BLAKE2b-256 checksum How to use checksums |
b16cc6947ea9ed77bac7f23240b84cf967869fbad7187339eeb4f74320a61ecd
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.12.7
|
Release files / sagar_neuron_gpt2-0.1.9-py3-none-any.whl
| Download URL | sagar_neuron_gpt2-0.1.9-py3-none-any.whl |
|---|---|
| Size | 195.2 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
be9f72222bd2675e9d565b0efc583f428130f88a8acf9037a28e1ac8b6f44364
|
|
BLAKE2b-256 checksum How to use checksums |
43ba1b1b9253aef2415794cb2a2fb14bf9d497b55470a88bac82621397996ca5
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.12.7
|
Security for sagar-neuron-gpt2 0.1.9
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.