Instructions to use YujiYamaguchi/lfm2-5-vl-450m-wildfire-precursor with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- PEFT
How to use YujiYamaguchi/lfm2-5-vl-450m-wildfire-precursor with PEFT:
from peft import PeftModel from transformers import AutoModelForCausalLM base_model = AutoModelForCausalLM.from_pretrained("LiquidAI/LFM2.5-VL-450M") model = PeftModel.from_pretrained(base_model, "YujiYamaguchi/lfm2-5-vl-450m-wildfire-precursor") - Transformers
How to use YujiYamaguchi/lfm2-5-vl-450m-wildfire-precursor with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-text-to-text", model="YujiYamaguchi/lfm2-5-vl-450m-wildfire-precursor") messages = [ { "role": "user", "content": [ {"type": "image", "url": "https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/p-blog/candy.JPG"}, {"type": "text", "text": "What animal is on the candy?"} ] }, ] pipe(text=messages)# Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("YujiYamaguchi/lfm2-5-vl-450m-wildfire-precursor", device_map="auto") - Notebooks
- Google Colab
- Kaggle
- Local Apps Settings
- vLLM
How to use YujiYamaguchi/lfm2-5-vl-450m-wildfire-precursor with vLLM:
Install from pip and serve model
# Install vLLM from pip: pip install vllm # Start the vLLM server: vllm serve "YujiYamaguchi/lfm2-5-vl-450m-wildfire-precursor" # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:8000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "YujiYamaguchi/lfm2-5-vl-450m-wildfire-precursor", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }'Use Docker
docker model run hf.co/YujiYamaguchi/lfm2-5-vl-450m-wildfire-precursor
- SGLang
How to use YujiYamaguchi/lfm2-5-vl-450m-wildfire-precursor with SGLang:
Install from pip and serve model
# Install SGLang from pip: pip install sglang # Start the SGLang server: python3 -m sglang.launch_server \ --model-path "YujiYamaguchi/lfm2-5-vl-450m-wildfire-precursor" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "YujiYamaguchi/lfm2-5-vl-450m-wildfire-precursor", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }'Use Docker images
docker run --gpus all \ --shm-size 32g \ -p 30000:30000 \ -v ~/.cache/huggingface:/root/.cache/huggingface \ --env "HF_TOKEN=<secret>" \ --ipc=host \ lmsysorg/sglang:latest \ python3 -m sglang.launch_server \ --model-path "YujiYamaguchi/lfm2-5-vl-450m-wildfire-precursor" \ --host 0.0.0.0 \ --port 30000 # Call the server using curl (OpenAI-compatible API): curl -X POST "http://localhost:30000/v1/chat/completions" \ -H "Content-Type: application/json" \ --data '{ "model": "YujiYamaguchi/lfm2-5-vl-450m-wildfire-precursor", "messages": [ { "role": "user", "content": [ { "type": "text", "text": "Describe this image in one sentence." }, { "type": "image_url", "image_url": { "url": "https://cdn.britannica.com/61/93061-050-99147DCE/Statue-of-Liberty-Island-New-York-Bay.jpg" } } ] } ] }' - Docker Model Runner
How to use YujiYamaguchi/lfm2-5-vl-450m-wildfire-precursor with Docker Model Runner:
docker model run hf.co/YujiYamaguchi/lfm2-5-vl-450m-wildfire-precursor
FireGuard β Pre-Fire Vegetation Drought Detection
LFM 2.5-VL-450M LoRA fine-tuned on Sentinel-2 NDMI time-series imagery
Detects vegetation drought stress 7β21 days before wildfire ignition using three-point time-series of Sentinel-2 false-color composites.
Built for the Liquid AI Γ DPhi Space "AI in Space" Hackathon 2026.
Model Details
- Base model:
LiquidAI/LFM2.5-VL-450M - Fine-tuning method: LoRA (r=8, alpha=16, dropout=0.05)
- Target modules: q/k/v/out_proj (attention), w1/w2/w3 (FFN), in_proj, linear_1/2 (multimodal projector)
- Training: 5 epochs, lr=2e-4, effective batch=4, bfloat16, RTX 5090
What It Does
Given three Sentinel-2 false-color composite images of the same chaparral location at β21 days / β14 days / β7 days before a reference date, the model predicts:
{"risk_level": "HIGH"} // vegetation progressively drying β elevated fire fuel risk
{"risk_level": "LOW"} // stable or moist vegetation
Image encoding (R=B12/SWIR22, G=B8A/NIR, B=B11/SWIR16):
- Blue channel darkening toward β7d β NDMI declining β drying stress signal
Evaluation Results
Test set: n=12 held-out chaparral scenes (6 HIGH / 6 LOW), California, 2017β2023
| Metric | Base LFM2.5-VL (zero-shot) | FireGuard LoRA |
|---|---|---|
| Precision | 0.500 | 1.000 |
| Recall | 1.000 | 1.000 |
| F1 | 0.667 | 1.000 |
| FP Rate | 1.000 | 0.000 |
| Latency | 283 ms | 208 ms |
The base model predicts every scene as HIGH risk (FP Rate = 1.0). Fine-tuning is essential.
Training Data
- Dataset:
YujiYamaguchi/fireguard-sentinel2-wildfire-precursor - POS: NASA FIRMS VIIRS_SNPP_SP California chaparral fire events β SimSat Sentinel-2 scenes at β21d/β14d/β7d before ignition
- NEG: Same coordinates, fire-free reference dates (FIRMS-verified)
- Split: train=100 / val=12 / test=12 (stratified, seed=42)
- Vegetation: California chaparral only (NDMI signal validated at p=0.038 for β7d lead time)
Usage
from transformers import AutoProcessor, AutoModelForImageTextToText
from peft import PeftModel
base = AutoModelForImageTextToText.from_pretrained("LiquidAI/LFM2.5-VL-450M")
model = PeftModel.from_pretrained(base, "YujiYamaguchi/lfm2-5-vl-450m-wildfire-precursor")
processor = AutoProcessor.from_pretrained("LiquidAI/LFM2.5-VL-450M")
See the FireGuard repository for full inference pipeline.
Citation
@misc{fireguard2026,
title = {FireGuard: Pre-Fire Vegetation Drought Detection via Sentinel-2 NDMI Time-Series},
author = {Yuji Yamaguchi},
year = {2026},
note = {Liquid AI Γ DPhi Space AI in Space Hackathon}
}
- Downloads last month
- 1
Model tree for YujiYamaguchi/lfm2-5-vl-450m-wildfire-precursor
Base model
LiquidAI/LFM2.5-350M-Base