Instructions to use q-future/one-align with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use q-future/one-align with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("zero-shot-image-classification", model="q-future/one-align", trust_remote_code=True) pipe( "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/hub/parrots.png", candidate_labels=["animals", "humans", "landscape"], )# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("q-future/one-align", trust_remote_code=True, dtype="auto") - Notebooks
- Google Colab
- Kaggle
Upload modeling_llama2.py with huggingface_hub
Browse files- modeling_llama2.py +1 -1
modeling_llama2.py
CHANGED
|
@@ -22,7 +22,7 @@ from transformers.configuration_utils import PretrainedConfig
|
|
| 22 |
from transformers.utils import logging
|
| 23 |
|
| 24 |
from .modeling_attn_mask_utils import _prepare_4d_causal_attention_mask
|
| 25 |
-
|
| 26 |
|
| 27 |
class MultiwayNetwork(nn.Module):
|
| 28 |
|
|
|
|
| 22 |
from transformers.utils import logging
|
| 23 |
|
| 24 |
from .modeling_attn_mask_utils import _prepare_4d_causal_attention_mask
|
| 25 |
+
from .configuration_mplug_owl2 import LlamaConfig
|
| 26 |
|
| 27 |
class MultiwayNetwork(nn.Module):
|
| 28 |
|