Image Segmentation
Transformers
Safetensors
English
falcon_x
feature-extraction
falcon-x
vision-language
custom_code
Instructions to use JonathanJMK/FALCON with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use JonathanJMK/FALCON with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-segmentation", model="JonathanJMK/FALCON", trust_remote_code=True)# pip install -U transformers accelerate # Load model directly from transformers import AutoModel model = AutoModel.from_pretrained("JonathanJMK/FALCON", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
|
Download README.md from JonathanJMK/FALCON: direct link, hf CLI and curl.
- Browser
- Download file 3.43 kB
-
https://huggingface.co/JonathanJMK/FALCON/resolve/main/README.md
- Command line
-
hf download hf://JonathanJMK/FALCON/README.md
-
curl -L -o README.md https://huggingface.co/JonathanJMK/FALCON/resolve/main/README.md
3.43 kB
| library_name: transformers | |
| license: llama2 | |
| base_model: | |
| - lmsys/vicuna-7b-v1.5 | |
| - facebook/dinov2-large | |
| tags: | |
| - falcon-x | |
| - vision-language | |
| - image-segmentation | |
| - custom_code | |
| language: | |
| - en | |
| # FALCON | |
| Functional Assembly and Language for Compositional Reasoning in X-ray. | |
| [Paper](https://arxiv.org/abs/2606.25701) 路 | |
| [Project page](https://yonathan-kiflom.github.io/FALCON/page/) 路 | |
| [Code](https://github.com/yonathan-kiflom/FALCON) | |
| This repository contains the completed Stage-3 model, including Vicuna-7B-v1.5, | |
| DINOv2-L/14, the trained RF-DETR segmentation detector, multimodal adapters, | |
| and unmerged LoRA weights. | |
| ## Usage | |
| Install the pinned dependencies from the code repository: | |
| ```bash | |
| pip install 'falcon-x[train] @ git+https://github.com/yonathan-kiflom/FALCON.git' | |
| ``` | |
| Use `JonathanJMK/FALCON` or a local downloaded model directory. Authenticate | |
| with `huggingface-cli login` when accessing the private repository. Review the | |
| custom code before trusting it; pin a Hub commit with `revision=` for reproducible use. | |
| ```python | |
| from transformers import AutoModel | |
| model = AutoModel.from_pretrained( | |
| "JonathanJMK/FALCON", trust_remote_code=True, | |
| ).to("cuda").eval() | |
| result, masks = model.predict( | |
| image="image.png", prompt="Describe the image.", max_new_tokens=256, | |
| ) | |
| print(result["answer"]) | |
| ``` | |
| Use `predict_segmentation` for grounding prompts and `predict_panoptic` for | |
| panoptic prompts. Tokenization, image preprocessing, and prompt formatting are | |
| included. The model supports one device; automatic multi-device dispatch and | |
| quantized loading are not supported. The saved per-component precision is | |
| preserved; do not cast the entire model to half precision. | |
| Evaluate using the same model: | |
| ```bash | |
| python -m falcon evaluate run --model JonathanJMK/FALCON \ | |
| --dataset /path/to/falcon-x --split test --tasks all \ | |
| --run-dir runs/falcon-evaluation --device cuda | |
| ``` | |
| ## Scope and limitations | |
| Trained on falcon-x for X-ray descriptions, questions, component | |
| presence/completeness, instance grounding, and segmentation. Generated answers | |
| and masks can be wrong; this is a research model, not a certified screening | |
| system. Available structured heads are declared in `config.json`; untrained | |
| risk and physical-link heads are not presented as predictions. Counterfactual | |
| completeness does not establish real-world danger or physical connectivity. | |
| The package preserves the trained architecture and LoRA for further research. | |
| It is not an optimizer-state checkpoint, and loading with Transformers alone | |
| does not make the repository's stage-training CLI a general fine-tuning tool. | |
| Task metrics and evaluation limitations are documented in the code repository. | |
| ## Licenses | |
| Vicuna is derived from Llama 2 and retains the | |
| [Llama 2 Community License](https://huggingface.co/meta-llama/Llama-2-7b/blob/main/LICENSE.txt) | |
| and [Acceptable Use Policy](https://huggingface.co/meta-llama/Llama-2-7b/blob/main/USE_POLICY.md). | |
| Llama 2 is licensed under the LLAMA 2 Community License, Copyright (c) Meta | |
| Platforms, Inc. All Rights Reserved. | |
| [DINOv2](https://github.com/facebookresearch/dinov2/blob/main/LICENSE) and | |
| [RF-DETR segmentation 1.5.2](https://github.com/roboflow/rf-detr/blob/1.5.2/LICENSE) | |
| use Apache-2.0. FALCON code is Apache-2.0 (`LICENSE-code`); this does not | |
| relicense upstream model weights. Retain `LICENSE-Llama-2`, `LICENSE-code` and | |
| `Notice` when redistributing the full package. | |