mistralrs_core/vision_models/
mod.rs

1use std::any::Any;
2
3use candle_core::Tensor;
4
5pub(crate) mod clip;
6pub(crate) mod idefics2;
7pub(crate) use idefics2::idefics2_input_processor;
8pub(crate) mod image_processor;
9pub(crate) mod llava;
10pub(crate) mod mllama;
11pub(crate) mod phi3;
12pub(crate) use phi3::phi3_inputs_processor;
13pub(crate) mod preprocessor_config;
14pub(crate) mod processor_config;
15pub(crate) mod qwen2_5_vl;
16pub(crate) mod qwen2vl;
17pub(crate) use llava::llava15;
18pub(crate) use llava::llava_inputs_processor;
19pub(crate) use llava::llava_next;
20pub(crate) use llava::llava_next_inputs_processor;
21pub(crate) mod idefics3;
22pub(crate) mod minicpmo;
23pub(crate) mod phi4;
24pub(crate) use phi4::inputs_processor;
25pub(crate) mod gemma3;
26pub(crate) mod mistral3;
27pub(crate) mod siglip;
28
29use crate::pipeline::text_models_inputs_processor::{FlashParams, PagedAttentionInputMetadata};
30
31pub struct ModelInputs {
32    pub input_ids: Tensor,
33    pub seqlen_offsets: Vec<usize>,
34    pub context_lens: Vec<(usize, usize)>,
35    pub position_ids: Vec<usize>,
36    pub pixel_values: Option<Tensor>,
37    pub model_specific_args: Box<dyn Any>,
38    pub paged_attn_meta: Option<PagedAttentionInputMetadata>,
39    pub flash_meta: FlashParams,
40}