Image-to-Text
Transformers
Safetensors
Arabic
lfm2_vl
image-text-to-text
arabic
vlm
image-captioning
siglip2
lfm2-vl
emhotob
Instructions to use oddadmix/Nawah-VL-50M with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use oddadmix/Nawah-VL-50M with Transformers:
# Use a pipeline as a high-level helper # Warning: Pipeline type "image-to-text" is no longer supported in transformers v5. # You must load the model directly (see below) or downgrade to v4.x with: # 'pip install "transformers<5.0.0' from transformers import pipeline pipe = pipeline("image-to-text", model="oddadmix/Nawah-VL-50M")# Load model directly from transformers import AutoProcessor, AutoModelForMultimodalLM processor = AutoProcessor.from_pretrained("oddadmix/Nawah-VL-50M") model = AutoModelForMultimodalLM.from_pretrained("oddadmix/Nawah-VL-50M", device_map="auto") - Notebooks
- Google Colab
- Kaggle
| { | |
| "architectures": [ | |
| "Lfm2VlForConditionalGeneration" | |
| ], | |
| "do_image_splitting": false, | |
| "downsample_factor": 2, | |
| "dtype": "bfloat16", | |
| "encoder_patch_size": 16, | |
| "image_token_id": 32000, | |
| "max_image_tokens": 64, | |
| "max_pixels_tolerance": 2.0, | |
| "max_tiles": 1, | |
| "min_image_tokens": 32, | |
| "min_tiles": 1, | |
| "model_type": "lfm2_vl", | |
| "projector_bias": true, | |
| "projector_hidden_act": "gelu", | |
| "projector_hidden_size": 2048, | |
| "projector_use_layernorm": false, | |
| "text_config": { | |
| "_name_or_path": "oddadmix/50M-2048-Emhotob", | |
| "architectures": [ | |
| "LlamaForCausalLM" | |
| ], | |
| "attention_bias": false, | |
| "attention_dropout": 0.0, | |
| "bos_token_id": 0, | |
| "dtype": "bfloat16", | |
| "eos_token_id": 2, | |
| "head_dim": 64, | |
| "hidden_act": "silu", | |
| "hidden_size": 512, | |
| "initializer_range": 0.02, | |
| "intermediate_size": 1408, | |
| "max_position_embeddings": 2048, | |
| "mlp_bias": false, | |
| "model_type": "llama", | |
| "num_attention_heads": 8, | |
| "num_hidden_layers": 12, | |
| "num_key_value_heads": 4, | |
| "pad_token_id": 1, | |
| "pretraining_tp": 1, | |
| "rms_norm_eps": 1e-06, | |
| "rope_parameters": { | |
| "rope_theta": 10000, | |
| "rope_type": "default" | |
| }, | |
| "tie_word_embeddings": true, | |
| "use_cache": true, | |
| "vocab_size": 32064 | |
| }, | |
| "tie_word_embeddings": true, | |
| "tile_size": 512, | |
| "transformers_version": "5.15.0", | |
| "use_image_special_tokens": true, | |
| "use_thumbnail": false, | |
| "vision_config": { | |
| "attention_dropout": 0.0, | |
| "dtype": "bfloat16", | |
| "hidden_act": "gelu_pytorch_tanh", | |
| "hidden_size": 768, | |
| "intermediate_size": 3072, | |
| "layer_norm_eps": 1e-06, | |
| "model_type": "siglip2_vision_model", | |
| "num_attention_heads": 12, | |
| "num_channels": 3, | |
| "num_hidden_layers": 12, | |
| "num_patches": 256, | |
| "patch_size": 16, | |
| "vision_use_head": false | |
| } | |
| } | |