Instructions to use TopAI-1/Pixel-1 with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use TopAI-1/Pixel-1 with Transformers:
# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("TopAI-1/Pixel-1", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
Update configuration_pixel.py
Browse files- configuration_pixel.py +2 -2
configuration_pixel.py
CHANGED
|
@@ -1,12 +1,12 @@
|
|
| 1 |
from transformers import PretrainedConfig
|
| 2 |
|
| 3 |
-
class
|
| 4 |
model_type = "topai_image_gen"
|
| 5 |
|
| 6 |
def __init__(
|
| 7 |
self,
|
| 8 |
input_dim=768,
|
| 9 |
-
hidden_dim=
|
| 10 |
image_channels=3,
|
| 11 |
resolution=128,
|
| 12 |
**kwargs
|
|
|
|
| 1 |
from transformers import PretrainedConfig
|
| 2 |
|
| 3 |
+
class TopAIImageConfig(PretrainedConfig): # <--- 讛砖诐 讛讝讛 拽专讬讟讬!
|
| 4 |
model_type = "topai_image_gen"
|
| 5 |
|
| 6 |
def __init__(
|
| 7 |
self,
|
| 8 |
input_dim=768,
|
| 9 |
+
hidden_dim=512,
|
| 10 |
image_channels=3,
|
| 11 |
resolution=128,
|
| 12 |
**kwargs
|