Files
agentic-studio/network-poc/target-native/doc/candle_transformers/models/index.html
2026-04-01 23:52:39 +03:00

14 lines
23 KiB
HTML
Raw Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
<!DOCTYPE html><html lang="en"><head><meta charset="utf-8"><meta name="viewport" content="width=device-width, initial-scale=1.0"><meta name="generator" content="rustdoc"><meta name="description" content="Candle implementations for various deep learning models"><title>candle_transformers::models - Rust</title><script>if(window.location.protocol!=="file:")document.head.insertAdjacentHTML("beforeend","SourceSerif4-Regular-6b053e98.ttf.woff2,FiraSans-Italic-81dc35de.woff2,FiraSans-Regular-0fe48ade.woff2,FiraSans-MediumItalic-ccf7e434.woff2,FiraSans-Medium-e1aa3f0a.woff2,SourceCodePro-Regular-8badfe75.ttf.woff2,SourceCodePro-Semibold-aa29a496.ttf.woff2".split(",").map(f=>`<link rel="preload" as="font" type="font/woff2"href="../../static.files/${f}">`).join(""))</script><link rel="stylesheet" href="../../static.files/normalize-9960930a.css"><link rel="stylesheet" href="../../static.files/rustdoc-77263533.css"><meta name="rustdoc-vars" data-root-path="../../" data-static-root-path="../../static.files/" data-current-crate="candle_transformers" data-themes="" data-resource-suffix="" data-rustdoc-version="1.94.1 (e408947bf 2026-03-25)" data-channel="1.94.1" data-search-js="search-9e2438ea.js" data-stringdex-js="stringdex-b897f86f.js" data-settings-js="settings-c38705f0.js" ><script src="../../static.files/storage-e2aeef58.js"></script><script defer src="../sidebar-items.js"></script><script defer src="../../static.files/main-7bab91a1.js"></script><noscript><link rel="stylesheet" href="../../static.files/noscript-ffcac47a.css"></noscript><link rel="alternate icon" type="image/png" href="../../static.files/favicon-32x32-eab170b8.png"><link rel="icon" type="image/svg+xml" href="../../static.files/favicon-044be391.svg"></head><body class="rustdoc mod"><!--[if lte IE 11]><div class="warning">This old browser is unsupported and will most likely display funky things.</div><![endif]--><rustdoc-topbar><h2><a href="#">Module models</a></h2></rustdoc-topbar><nav class="sidebar"><div class="sidebar-crate"><h2><a href="../../candle_transformers/index.html">candle_<wbr>transformers</a><span class="version">0.8.4</span></h2></div><div class="sidebar-elems"><section id="rustdoc-toc"><h2 class="location"><a href="#">Module models</a></h2><h3><a href="#modules">Module Items</a></h3><ul class="block"><li><a href="#modules" title="Modules">Modules</a></li></ul></section><div id="rustdoc-modnav"><h2 class="in-crate"><a href="../index.html">In crate candle_<wbr>transformers</a></h2></div></div></nav><div class="sidebar-resizer" title="Drag to resize sidebar"></div><main><div class="width-limiter"><section id="main-content" class="content"><div class="main-heading"><div class="rustdoc-breadcrumbs"><a href="../index.html">candle_transformers</a></div><h1>Module <span>models</span>&nbsp;<button id="copy-path" title="Copy item path to clipboard">Copy item path</button></h1><rustdoc-toolbar></rustdoc-toolbar><span class="sub-heading"><a class="src" href="../../src/candle_transformers/models/mod.rs.html#1-118">Source</a> </span></div><details class="toggle top-doc" open><summary class="hideme"><span>Expand description</span></summary><div class="docblock"><p>Candle implementations for various deep learning models</p>
<p>This crate provides implementations of popular machine learning models and architectures for different modalities.</p>
<ul>
<li>Large language models: <a href="llama/index.html" title="mod candle_transformers::models::llama"><code>llama</code></a>, <a href="phi3/index.html" title="mod candle_transformers::models::phi3"><code>phi3</code></a>, <a href="mamba/index.html" title="mod candle_transformers::models::mamba"><code>mamba</code></a>, <a href="mixtral/index.html" title="mod candle_transformers::models::mixtral"><code>mixtral</code></a>, <a href="bert/index.html" title="mod candle_transformers::models::bert"><code>bert</code></a>, …</li>
<li>Text to text models: <a href="t5/index.html" title="mod candle_transformers::models::t5"><code>t5</code></a>, …</li>
<li>Image to text models: <a href="blip/index.html" title="mod candle_transformers::models::blip"><code>blip</code></a>, …</li>
<li>Text to image models: <a href="stable_diffusion/index.html" title="mod candle_transformers::models::stable_diffusion"><code>stable_diffusion</code></a> and <a href="wuerstchen/index.html" title="mod candle_transformers::models::wuerstchen"><code>wuerstchen</code></a>, …</li>
<li>Audio models: <a href="whisper/index.html" title="mod candle_transformers::models::whisper"><code>whisper</code></a>, <a href="encodec/index.html" title="mod candle_transformers::models::encodec"><code>encodec</code></a>, <a href="metavoice/index.html" title="mod candle_transformers::models::metavoice"><code>metavoice</code></a>, <a href="parler_tts/index.html" title="mod candle_transformers::models::parler_tts"><code>parler_tts</code></a>, …</li>
<li>Computer vision models: <a href="dinov2/index.html" title="mod candle_transformers::models::dinov2"><code>dinov2</code></a>, <a href="convmixer/index.html" title="mod candle_transformers::models::convmixer"><code>convmixer</code></a>, <a href="efficientnet/index.html" title="mod candle_transformers::models::efficientnet"><code>efficientnet</code></a>, …</li>
</ul>
<p>Some of the models also have quantized variants, e.g. <a href="quantized_blip/index.html" title="mod candle_transformers::models::quantized_blip"><code>quantized_blip</code></a>, <a href="quantized_llama/index.html" title="mod candle_transformers::models::quantized_llama"><code>quantized_llama</code></a> and <a href="quantized_qwen2/index.html" title="mod candle_transformers::models::quantized_qwen2"><code>quantized_qwen2</code></a>.</p>
<p>The implementations aim to be readable while maintaining good performance. For more information
on each model see the models module docs in the links below.</p>
</div></details><h2 id="modules" class="section-header">Modules<a href="#modules" class="anchor">§</a></h2><dl class="item-table"><dt><a class="mod" href="based/index.html" title="mod candle_transformers::models::based">based</a></dt><dd>Based from the Stanford Hazy Research group.</dd><dt><a class="mod" href="beit/index.html" title="mod candle_transformers::models::beit">beit</a></dt><dd>Based on the BEIT vision-language model.</dd><dt><a class="mod" href="bert/index.html" title="mod candle_transformers::models::bert">bert</a></dt><dd>BERT (Bidirectional Encoder Representations from Transformers)</dd><dt><a class="mod" href="bigcode/index.html" title="mod candle_transformers::models::bigcode">bigcode</a></dt><dd>BigCode implementation in Rust based on the GPT-BigCode model.</dd><dt><a class="mod" href="blip/index.html" title="mod candle_transformers::models::blip">blip</a></dt><dd>Based on the BLIP paper from Salesforce Research.</dd><dt><a class="mod" href="blip_text/index.html" title="mod candle_transformers::models::blip_text">blip_<wbr>text</a></dt><dd>Implementation of BLIP text encoder/decoder.</dd><dt><a class="mod" href="chatglm/index.html" title="mod candle_transformers::models::chatglm">chatglm</a></dt><dd>Implementation of the ChatGLM2/3 models from THUDM.</dd><dt><a class="mod" href="chinese_clip/index.html" title="mod candle_transformers::models::chinese_clip">chinese_<wbr>clip</a></dt><dd>Chinese contrastive Language-Image Pre-Training</dd><dt><a class="mod" href="clip/index.html" title="mod candle_transformers::models::clip">clip</a></dt><dd>Contrastive Language-Image Pre-Training</dd><dt><a class="mod" href="codegeex4_9b/index.html" title="mod candle_transformers::models::codegeex4_9b">codegeex4_<wbr>9b</a></dt><dd>CodeGeeX4 - A multi-language code generation model</dd><dt><a class="mod" href="colpali/index.html" title="mod candle_transformers::models::colpali">colpali</a></dt><dd>Colpali Model for text/image similarity scoring.</dd><dt><a class="mod" href="convmixer/index.html" title="mod candle_transformers::models::convmixer">convmixer</a></dt><dd>ConvMixer implementation.</dd><dt><a class="mod" href="convnext/index.html" title="mod candle_transformers::models::convnext">convnext</a></dt><dd>ConvNeXt implementation.</dd><dt><a class="mod" href="dac/index.html" title="mod candle_transformers::models::dac">dac</a></dt><dd>Implementation of the Descript Audio Codec (DAC) model</dd><dt><a class="mod" href="debertav2/index.html" title="mod candle_transformers::models::debertav2">debertav2</a></dt><dt><a class="mod" href="deepseek2/index.html" title="mod candle_transformers::models::deepseek2">deepseek2</a></dt><dt><a class="mod" href="depth_anything_v2/index.html" title="mod candle_transformers::models::depth_anything_v2">depth_<wbr>anything_<wbr>v2</a></dt><dd>Implementation of the Depth Anything model from FAIR.</dd><dt><a class="mod" href="dinov2/index.html" title="mod candle_transformers::models::dinov2">dinov2</a></dt><dd>Implementation of the DINOv2 models from Meta Research.</dd><dt><a class="mod" href="dinov2reg4/index.html" title="mod candle_transformers::models::dinov2reg4">dinov2reg4</a></dt><dd>Implementation of the DINOv2 revision (4 regularization)</dd><dt><a class="mod" href="distilbert/index.html" title="mod candle_transformers::models::distilbert">distilbert</a></dt><dd>Implementation of DistilBert, a distilled version of BERT.</dd><dt><a class="mod" href="efficientnet/index.html" title="mod candle_transformers::models::efficientnet">efficientnet</a></dt><dd>Implementation of EfficientBert, an efficient variant of BERT for computer vision tasks.</dd><dt><a class="mod" href="efficientvit/index.html" title="mod candle_transformers::models::efficientvit">efficientvit</a></dt><dd>EfficientViT (MSRA) inference implementation based on timm.</dd><dt><a class="mod" href="encodec/index.html" title="mod candle_transformers::models::encodec">encodec</a></dt><dd>EnCodec neural audio codec based on the Encodec implementation.</dd><dt><a class="mod" href="eva2/index.html" title="mod candle_transformers::models::eva2">eva2</a></dt><dd>EVA-2 inference implementation.</dd><dt><a class="mod" href="falcon/index.html" title="mod candle_transformers::models::falcon">falcon</a></dt><dd>Falcon language model inference implementation</dd><dt><a class="mod" href="fastvit/index.html" title="mod candle_transformers::models::fastvit">fastvit</a></dt><dd>FastViT inference implementation based on timm</dd><dt><a class="mod" href="flux/index.html" title="mod candle_transformers::models::flux">flux</a></dt><dd>Flux Model</dd><dt><a class="mod" href="gemma/index.html" title="mod candle_transformers::models::gemma">gemma</a></dt><dd>Gemma inference implementation.</dd><dt><a class="mod" href="gemma2/index.html" title="mod candle_transformers::models::gemma2">gemma2</a></dt><dd>Gemma LLM architecture (Google) inference implementation.</dd><dt><a class="mod" href="gemma3/index.html" title="mod candle_transformers::models::gemma3">gemma3</a></dt><dd>Gemma LLM architecture (Google) inference implementation.</dd><dt><a class="mod" href="glm4/index.html" title="mod candle_transformers::models::glm4">glm4</a></dt><dd>GLM-4 inference implementation.</dd><dt><a class="mod" href="granite/index.html" title="mod candle_transformers::models::granite">granite</a></dt><dd>Granite is a Long Context Transformer Language Model.</dd><dt><a class="mod" href="helium/index.html" title="mod candle_transformers::models::helium">helium</a></dt><dd>Helium inference implementation.</dd><dt><a class="mod" href="hiera/index.html" title="mod candle_transformers::models::hiera">hiera</a></dt><dd>Hiera inference implementation based on timm.</dd><dt><a class="mod" href="jina_bert/index.html" title="mod candle_transformers::models::jina_bert">jina_<wbr>bert</a></dt><dd>JinaBERT inference implementation</dd><dt><a class="mod" href="llama/index.html" title="mod candle_transformers::models::llama">llama</a></dt><dd>Llama inference implementation.</dd><dt><a class="mod" href="llama2_c/index.html" title="mod candle_transformers::models::llama2_c">llama2_<wbr>c</a></dt><dd>Llama2 inference implementation.</dd><dt><a class="mod" href="llama2_c_weights/index.html" title="mod candle_transformers::models::llama2_c_weights">llama2_<wbr>c_<wbr>weights</a></dt><dd>Llama2 inference implementation.</dd><dt><a class="mod" href="llava/index.html" title="mod candle_transformers::models::llava">llava</a></dt><dd>The LLaVA (Large Language and Vision Assistant) model.</dd><dt><a class="mod" href="mamba/index.html" title="mod candle_transformers::models::mamba">mamba</a></dt><dd>Mamba inference implementation.</dd><dt><a class="mod" href="marian/index.html" title="mod candle_transformers::models::marian">marian</a></dt><dd>Marian Neural Machine Translation</dd><dt><a class="mod" href="metavoice/index.html" title="mod candle_transformers::models::metavoice">metavoice</a></dt><dd>MetaVoice Studio ML Models</dd><dt><a class="mod" href="mimi/index.html" title="mod candle_transformers::models::mimi">mimi</a></dt><dd>mimi model</dd><dt><a class="mod" href="mistral/index.html" title="mod candle_transformers::models::mistral">mistral</a></dt><dd>Mixtral Model, based on the Mistral architecture</dd><dt><a class="mod" href="mixformer/index.html" title="mod candle_transformers::models::mixformer">mixformer</a></dt><dd>MixFormer (Microsofts Phi Architecture)</dd><dt><a class="mod" href="mixtral/index.html" title="mod candle_transformers::models::mixtral">mixtral</a></dt><dd>Mixtral Model, a sparse mixture of expert model based on the Mistral architecture</dd><dt><a class="mod" href="mmdit/index.html" title="mod candle_transformers::models::mmdit">mmdit</a></dt><dd>Mix of Multi-scale Dilated and Traditional Convolutions</dd><dt><a class="mod" href="mobileclip/index.html" title="mod candle_transformers::models::mobileclip">mobileclip</a></dt><dd>Mobile CLIP model, combining a lightweight vision encoder with a text encoder</dd><dt><a class="mod" href="mobilenetv4/index.html" title="mod candle_transformers::models::mobilenetv4">mobilenetv4</a></dt><dd>MobileNet-v4</dd><dt><a class="mod" href="mobileone/index.html" title="mod candle_transformers::models::mobileone">mobileone</a></dt><dd>MobileOne</dd><dt><a class="mod" href="modernbert/index.html" title="mod candle_transformers::models::modernbert">modernbert</a></dt><dd>ModernBERT</dd><dt><a class="mod" href="moondream/index.html" title="mod candle_transformers::models::moondream">moondream</a></dt><dd>MoonDream Model vision-to-text</dd><dt><a class="mod" href="mpt/index.html" title="mod candle_transformers::models::mpt">mpt</a></dt><dd>Module implementing the MPT (Multi-Purpose Transformer) model</dd><dt><a class="mod" href="nvembed_v2/index.html" title="mod candle_transformers::models::nvembed_v2">nvembed_<wbr>v2</a></dt><dd>NV-Embed-v2</dd><dt><a class="mod" href="olmo/index.html" title="mod candle_transformers::models::olmo">olmo</a></dt><dd>OLMo (Open Language Model) implementation</dd><dt><a class="mod" href="openclip/index.html" title="mod candle_transformers::models::openclip">openclip</a></dt><dd>Open Contrastive Language-Image Pre-Training</dd><dt><a class="mod" href="paligemma/index.html" title="mod candle_transformers::models::paligemma">paligemma</a></dt><dd>Multimodal multi-purpose model combining Gemma-based language model with SigLIP image understanding</dd><dt><a class="mod" href="parler_tts/index.html" title="mod candle_transformers::models::parler_tts">parler_<wbr>tts</a></dt><dd>Parler Model implementation for parler_tts text-to-speech synthesis</dd><dt><a class="mod" href="persimmon/index.html" title="mod candle_transformers::models::persimmon">persimmon</a></dt><dd>Persimmon Model</dd><dt><a class="mod" href="phi/index.html" title="mod candle_transformers::models::phi">phi</a></dt><dd>Microsoft Phi model implementation</dd><dt><a class="mod" href="phi3/index.html" title="mod candle_transformers::models::phi3">phi3</a></dt><dd>Microsoft Phi-3 model implementation</dd><dt><a class="mod" href="pixtral/index.html" title="mod candle_transformers::models::pixtral">pixtral</a></dt><dd>Pixtral Language-Image Pre-Training</dd><dt><a class="mod" href="quantized_blip/index.html" title="mod candle_transformers::models::quantized_blip">quantized_<wbr>blip</a></dt><dd>BLIP model implementation with quantization support.</dd><dt><a class="mod" href="quantized_blip_text/index.html" title="mod candle_transformers::models::quantized_blip_text">quantized_<wbr>blip_<wbr>text</a></dt><dd>Quantized BLIP text module implementation.</dd><dt><a class="mod" href="quantized_llama/index.html" title="mod candle_transformers::models::quantized_llama">quantized_<wbr>llama</a></dt><dd>Quantized llama model implementation.</dd><dt><a class="mod" href="quantized_llama2_c/index.html" title="mod candle_transformers::models::quantized_llama2_c">quantized_<wbr>llama2_<wbr>c</a></dt><dd>Quantized Llama2 model implementation.</dd><dt><a class="mod" href="quantized_metavoice/index.html" title="mod candle_transformers::models::quantized_metavoice">quantized_<wbr>metavoice</a></dt><dd>Quantized MetaVoice model implementation.</dd><dt><a class="mod" href="quantized_mistral/index.html" title="mod candle_transformers::models::quantized_mistral">quantized_<wbr>mistral</a></dt><dd>Mistral model implementation with quantization support.</dd><dt><a class="mod" href="quantized_mixformer/index.html" title="mod candle_transformers::models::quantized_mixformer">quantized_<wbr>mixformer</a></dt><dd>Module containing quantized MixFormer model implementation.</dd><dt><a class="mod" href="quantized_moondream/index.html" title="mod candle_transformers::models::quantized_moondream">quantized_<wbr>moondream</a></dt><dd>Implementation of a quantized Moondream vision language model.</dd><dt><a class="mod" href="quantized_mpt/index.html" title="mod candle_transformers::models::quantized_mpt">quantized_<wbr>mpt</a></dt><dd>Quantized MPT model implementation.</dd><dt><a class="mod" href="quantized_phi/index.html" title="mod candle_transformers::models::quantized_phi">quantized_<wbr>phi</a></dt><dd>Phi2 model implementation with quantization support.</dd><dt><a class="mod" href="quantized_phi3/index.html" title="mod candle_transformers::models::quantized_phi3">quantized_<wbr>phi3</a></dt><dd>Phi3 model implementation with quantization support.</dd><dt><a class="mod" href="quantized_qwen2/index.html" title="mod candle_transformers::models::quantized_qwen2">quantized_<wbr>qwen2</a></dt><dd>Qwen2 model implementation with quantization support.</dd><dt><a class="mod" href="quantized_recurrent_gemma/index.html" title="mod candle_transformers::models::quantized_recurrent_gemma">quantized_<wbr>recurrent_<wbr>gemma</a></dt><dd>Recurrent Gemma model implementation with quantization support.</dd><dt><a class="mod" href="quantized_rwkv_v5/index.html" title="mod candle_transformers::models::quantized_rwkv_v5">quantized_<wbr>rwkv_<wbr>v5</a></dt><dd>RWKV v5 model implementation with quantization support.</dd><dt><a class="mod" href="quantized_rwkv_v6/index.html" title="mod candle_transformers::models::quantized_rwkv_v6">quantized_<wbr>rwkv_<wbr>v6</a></dt><dd>RWKV v6 model implementation with quantization support.</dd><dt><a class="mod" href="quantized_stable_lm/index.html" title="mod candle_transformers::models::quantized_stable_lm">quantized_<wbr>stable_<wbr>lm</a></dt><dd>Module for quantized StableLM implementation.</dd><dt><a class="mod" href="quantized_t5/index.html" title="mod candle_transformers::models::quantized_t5">quantized_<wbr>t5</a></dt><dd>T5 model implementation with quantization support.</dd><dt><a class="mod" href="qwen2/index.html" title="mod candle_transformers::models::qwen2">qwen2</a></dt><dd>Qwen2 model implementation with quantization support.</dd><dt><a class="mod" href="qwen2_moe/index.html" title="mod candle_transformers::models::qwen2_moe">qwen2_<wbr>moe</a></dt><dd>Qwen2 model implementation with Mixture of Experts support.</dd><dt><a class="mod" href="recurrent_gemma/index.html" title="mod candle_transformers::models::recurrent_gemma">recurrent_<wbr>gemma</a></dt><dd>Recurrent Gemma model implementation</dd><dt><a class="mod" href="repvgg/index.html" title="mod candle_transformers::models::repvgg">repvgg</a></dt><dd>RepVGG inference implementation</dd><dt><a class="mod" href="resnet/index.html" title="mod candle_transformers::models::resnet">resnet</a></dt><dd>ResNet Implementation</dd><dt><a class="mod" href="rwkv_v5/index.html" title="mod candle_transformers::models::rwkv_v5">rwkv_v5</a></dt><dd>RWKV v5 model implementation.</dd><dt><a class="mod" href="rwkv_v6/index.html" title="mod candle_transformers::models::rwkv_v6">rwkv_v6</a></dt><dd>RWKV v6 model implementation.</dd><dt><a class="mod" href="segformer/index.html" title="mod candle_transformers::models::segformer">segformer</a></dt><dd>Segformer model implementation for semantic segmentation and image classification.</dd><dt><a class="mod" href="segment_anything/index.html" title="mod candle_transformers::models::segment_anything">segment_<wbr>anything</a></dt><dd>Segment Anything Model (SAM)</dd><dt><a class="mod" href="siglip/index.html" title="mod candle_transformers::models::siglip">siglip</a></dt><dd>Siglip model implementation.</dd><dt><a class="mod" href="stable_diffusion/index.html" title="mod candle_transformers::models::stable_diffusion">stable_<wbr>diffusion</a></dt><dd>Stable Diffusion</dd><dt><a class="mod" href="stable_lm/index.html" title="mod candle_transformers::models::stable_lm">stable_<wbr>lm</a></dt><dd>StableLM model implementation.</dd><dt><a class="mod" href="starcoder2/index.html" title="mod candle_transformers::models::starcoder2">starcoder2</a></dt><dd>StarCoder model implementation with quantization support.</dd><dt><a class="mod" href="stella_en_v5/index.html" title="mod candle_transformers::models::stella_en_v5">stella_<wbr>en_<wbr>v5</a></dt><dd>Stella v5 model implementation.</dd><dt><a class="mod" href="t5/index.html" title="mod candle_transformers::models::t5">t5</a></dt><dd>T5 model implementation.</dd><dt><a class="mod" href="trocr/index.html" title="mod candle_transformers::models::trocr">trocr</a></dt><dd>TrOCR model implementation.</dd><dt><a class="mod" href="vgg/index.html" title="mod candle_transformers::models::vgg">vgg</a></dt><dd>VGG-16 model implementation.</dd><dt><a class="mod" href="vit/index.html" title="mod candle_transformers::models::vit">vit</a></dt><dd>Vision Transformer (ViT) implementation.</dd><dt><a class="mod" href="whisper/index.html" title="mod candle_transformers::models::whisper">whisper</a></dt><dd>Whisper Model Implementation</dd><dt><a class="mod" href="with_tracing/index.html" title="mod candle_transformers::models::with_tracing">with_<wbr>tracing</a></dt><dt><a class="mod" href="wuerstchen/index.html" title="mod candle_transformers::models::wuerstchen">wuerstchen</a></dt><dd>Würstchen Efficient Diffusion Model</dd><dt><a class="mod" href="xlm_roberta/index.html" title="mod candle_transformers::models::xlm_roberta">xlm_<wbr>roberta</a></dt><dt><a class="mod" href="yi/index.html" title="mod candle_transformers::models::yi">yi</a></dt><dd>Yi model implementation.</dd></dl></section></div></main></body></html>