Skip to content
/ pxia Public

minimalistic AI library that resembles HF's transformers

License

Notifications You must be signed in to change notification settings

not-lain/pxia

Repository files navigation

PXIA

A repository for pxia models

This repository is using HuggingFace's PyTorchModelHubMixin classes

Downloads

How to use

pip install pxia
from pxia import GPT2
model = GPT2(block_size= 1024, vocab_size = 50257, n_layer= 11, n_head= 12, n_embed = 768) # or use default parameters
model.push_to_hub("phxia/gpt2")

pretrained_model = GPT2.from_pretrained("phxia/gpt2")

alternatively you can load weights from source gpt2 models from huggingface and convert them to pxia format

model = GPT2.from_origin("openai-community/gpt2")

we also support AutoModel class in our repository to load any pxia model either locally or from the hub you can

from pxia import AutoModel
model = AutoModel.from_pretrained("phxia/gpt2")

pxia

About

minimalistic AI library that resembles HF's transformers

Topics

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages