text
stringlengths
5
58.6k
source
stringclasses
470 values
url
stringlengths
49
167
source_section
stringlengths
0
90
file_type
stringclasses
1 value
id
stringlengths
3
6
GPTSAN has the structure of the model named Prefix-LM in the `T5` paper. (The original GPTSAN repository calls it `hybrid`) In GPTSAN, the `Prefix` part of Prefix-LM, that is, the input position that can be referenced by both tokens, can be specified with any length. Arbitrary lengths can also be specified differently ...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/gptsan-japanese.md
https://huggingface.co/docs/transformers/en/model_doc/gptsan-japanese/#prefix-lm-model
#prefix-lm-model
.md
360_5
Specifying the Prefix part is done with a mask passed to self-attention. When token_type_ids=None or all zero, it is equivalent to regular causal mask for example: >>> x_token = tokenizer("アイウエ") input_ids: | SOT | SEG | ア | イ | ウ | エ | token_type_ids: | 1 | 0 | 0 | 0 | 0 | 0 | prefix_lm_mask: SOT | 1 0 0 ...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/gptsan-japanese.md
https://huggingface.co/docs/transformers/en/model_doc/gptsan-japanese/#usage-tips
#usage-tips
.md
360_6
A Spout Vector is a special vector for controlling text generation. This vector is treated as the first embedding in self-attention to bring extraneous attention to the generated tokens. In the pre-trained model published from `Tanrei/GPTSAN-japanese`, the Spout Vector is a 128-dimensional vector that passes through 8 ...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/gptsan-japanese.md
https://huggingface.co/docs/transformers/en/model_doc/gptsan-japanese/#spout-vector
#spout-vector
.md
360_7
This is the configuration class to store the configuration of a [`GPTSanJapaneseModel`]. It is used to instantiate a GPTSANJapanese model according to the specified arguments, defining the model architecture. Instantiating a configuration with the defaults will yield a similar configuration to that of the GPTSANJapanes...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/gptsan-japanese.md
https://huggingface.co/docs/transformers/en/model_doc/gptsan-japanese/#gptsanjapaneseconfig
#gptsanjapaneseconfig
.md
360_8
This tokenizer is based on GPTNeoXJapaneseTokenizer and has the following modifications - Decoding byte0~byte255 tokens correctly - Added bagofword token handling - Return token_type_ids for Prefix-LM model The bagofword token represents a repetition of the previous token and is converted to 3 consecutive tokens when d...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/gptsan-japanese.md
https://huggingface.co/docs/transformers/en/model_doc/gptsan-japanese/#gptsanjapanesetokenizer
#gptsanjapanesetokenizer
.md
360_9
The bare GPTSAN-japanese Model transformer outputting raw hidden-states without any specific head on top. The [GPTSAN-japanese](https://github.com/tanreinama/GPTSAN) model was proposed in General-purpose Swich transformer based Japanese language model This model is also a PyTorch [torch.nn.Module](https://pytorch.o...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/gptsan-japanese.md
https://huggingface.co/docs/transformers/en/model_doc/gptsan-japanese/#gptsanjapanesemodel
#gptsanjapanesemodel
.md
360_10
The bare GPTSAN-japanese Model with a language modeling head. The [GPTSAN-japanese](https://github.com/tanreinama/GPTSAN) model was proposed in General-purpose Swich transformer based Japanese language model This model is also a PyTorch [torch.nn.Module](https://pytorch.org/docs/stable/nn.html#torch.nn.Module) subc...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/gptsan-japanese.md
https://huggingface.co/docs/transformers/en/model_doc/gptsan-japanese/#gptsanjapaneseforconditionalgeneration
#gptsanjapaneseforconditionalgeneration
.md
360_11
<!--Copyright 2022 The HuggingFace Team. All rights reserved. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agr...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/nat.md
https://huggingface.co/docs/transformers/en/model_doc/nat/
.md
361_0
<Tip warning={true}> This model is in maintenance mode only, we don't accept any new PRs changing its code. If you run into any issues running this model, please reinstall the last version that supported this model: v4.40.2. You can do so by running the following command: `pip install -U transformers==4.40.2`. </Ti...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/nat.md
https://huggingface.co/docs/transformers/en/model_doc/nat/#neighborhood-attention-transformer
#neighborhood-attention-transformer
.md
361_1
NAT was proposed in [Neighborhood Attention Transformer](https://arxiv.org/abs/2204.07143) by Ali Hassani, Steven Walton, Jiachen Li, Shen Li, and Humphrey Shi. It is a hierarchical vision transformer based on Neighborhood Attention, a sliding-window self attention pattern. The abstract from the paper is the follow...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/nat.md
https://huggingface.co/docs/transformers/en/model_doc/nat/#overview
#overview
.md
361_2
- One can use the [`AutoImageProcessor`] API to prepare images for the model. - NAT can be used as a *backbone*. When `output_hidden_states = True`, it will output both `hidden_states` and `reshaped_hidden_states`. The `reshaped_hidden_states` have a shape of `(batch, num_channels, height, width)` rather than `(batch_s...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/nat.md
https://huggingface.co/docs/transformers/en/model_doc/nat/#usage-tips
#usage-tips
.md
361_3
A list of official Hugging Face and community (indicated by 🌎) resources to help you get started with NAT. <PipelineTag pipeline="image-classification"/> - [`NatForImageClassification`] is supported by this [example script](https://github.com/huggingface/transformers/tree/main/examples/pytorch/image-classification...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/nat.md
https://huggingface.co/docs/transformers/en/model_doc/nat/#resources
#resources
.md
361_4
This is the configuration class to store the configuration of a [`NatModel`]. It is used to instantiate a Nat model according to the specified arguments, defining the model architecture. Instantiating a configuration with the defaults will yield a similar configuration to that of the Nat [shi-labs/nat-mini-in1k-224](ht...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/nat.md
https://huggingface.co/docs/transformers/en/model_doc/nat/#natconfig
#natconfig
.md
361_5
The bare Nat Model transformer outputting raw hidden-states without any specific head on top. This model is a PyTorch [torch.nn.Module](https://pytorch.org/docs/stable/nn.html#torch.nn.Module) sub-class. Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage an...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/nat.md
https://huggingface.co/docs/transformers/en/model_doc/nat/#natmodel
#natmodel
.md
361_6
Nat Model transformer with an image classification head on top (a linear layer on top of the final hidden state of the [CLS] token) e.g. for ImageNet. This model is a PyTorch [torch.nn.Module](https://pytorch.org/docs/stable/nn.html#torch.nn.Module) sub-class. Use it as a regular PyTorch Module and refer to the PyTor...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/nat.md
https://huggingface.co/docs/transformers/en/model_doc/nat/#natforimageclassification
#natforimageclassification
.md
361_7
<!--Copyright 2024 The HuggingFace Team. All rights reserved. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agr...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/pixtral.md
https://huggingface.co/docs/transformers/en/model_doc/pixtral/
.md
362_0
The Pixtral model was released by the Mistral AI team in a [blog post](https://mistral.ai/news/pixtral-12b/). Pixtral is a multimodal version of [Mistral](mistral), incorporating a 400 million parameter vision encoder trained from scratch. The intro from the blog says the following: *Pixtral is trained to understan...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/pixtral.md
https://huggingface.co/docs/transformers/en/model_doc/pixtral/#overview
#overview
.md
362_1
At inference time, it's advised to use the processor's `apply_chat_template` method, which correctly formats the prompt for the model: ```python from transformers import AutoProcessor, LlavaForConditionalGeneration from PIL import Image model_id = "mistral-community/pixtral-12b" processor = AutoProcessor.from_pretra...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/pixtral.md
https://huggingface.co/docs/transformers/en/model_doc/pixtral/#usage
#usage
.md
362_2
This is the configuration class to store the configuration of a [`PixtralVisionModel`]. It is used to instantiate an Pixtral vision encoder according to the specified arguments, defining the model architecture. Instantiating a configuration with the defaults will yield a similar configuration to the vision encoder used...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/pixtral.md
https://huggingface.co/docs/transformers/en/model_doc/pixtral/#pixtralvisionconfig
#pixtralvisionconfig
.md
362_3
The bare Pixtral vision encoder outputting raw hidden-states without any specific head on top. This model inherits from [`PreTrainedModel`]. Check the superclass documentation for the generic methods the library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads et...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/pixtral.md
https://huggingface.co/docs/transformers/en/model_doc/pixtral/#pixtralvisionmodel
#pixtralvisionmodel
.md
362_4
Constructs a Pixtral image processor. Args: do_resize (`bool`, *optional*, defaults to `True`): Whether to resize the image's (height, width) dimensions to the specified `size`. Can be overridden by `do_resize` in the `preprocess` method. size (`Dict[str, int]` *optional*, defaults to `{"longest_edge": 1024}`): Size ...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/pixtral.md
https://huggingface.co/docs/transformers/en/model_doc/pixtral/#pixtralimageprocessor
#pixtralimageprocessor
.md
362_5
Constructs a fast Pixtral image processor that leverages torchvision. Args: do_resize (`bool`, *optional*, defaults to `True`): Whether to resize the image's (height, width) dimensions to the specified `size`. Can be overridden by `do_resize` in the `preprocess` method. size (`Dict[str, int]` *optional*, defaults to ...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/pixtral.md
https://huggingface.co/docs/transformers/en/model_doc/pixtral/#pixtralimageprocessorfast
#pixtralimageprocessorfast
.md
362_6
Constructs a Pixtral processor which wraps a Pixtral image processor and a Pixtral tokenizer into a single processor. [`PixtralProcessor`] offers all the functionalities of [`CLIPImageProcessor`] and [`LlamaTokenizerFast`]. See the [`~PixtralProcessor.__call__`] and [`~PixtralProcessor.decode`] for more information. ...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/pixtral.md
https://huggingface.co/docs/transformers/en/model_doc/pixtral/#pixtralprocessor
#pixtralprocessor
.md
362_7
<!--Copyright 2024 The HuggingFace Team. All rights reserved. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agr...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/depth_anything_v2.md
https://huggingface.co/docs/transformers/en/model_doc/depth_anything_v2/
.md
363_0
Depth Anything V2 was introduced in [the paper of the same name](https://arxiv.org/abs/2406.09414) by Lihe Yang et al. It uses the same architecture as the original [Depth Anything model](depth_anything), but uses synthetic data and a larger capacity teacher model to achieve much finer and robust depth predictions. T...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/depth_anything_v2.md
https://huggingface.co/docs/transformers/en/model_doc/depth_anything_v2/#overview
#overview
.md
363_1
There are 2 main ways to use Depth Anything V2: either using the pipeline API, which abstracts away all the complexity for you, or by using the `DepthAnythingForDepthEstimation` class yourself.
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/depth_anything_v2.md
https://huggingface.co/docs/transformers/en/model_doc/depth_anything_v2/#usage-example
#usage-example
.md
363_2
The pipeline allows to use the model in a few lines of code: ```python >>> from transformers import pipeline >>> from PIL import Image >>> import requests >>> # load pipe >>> pipe = pipeline(task="depth-estimation", model="depth-anything/Depth-Anything-V2-Small-hf") >>> # load image >>> url = 'http://images.cocodat...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/depth_anything_v2.md
https://huggingface.co/docs/transformers/en/model_doc/depth_anything_v2/#pipeline-api
#pipeline-api
.md
363_3
If you want to do the pre- and post-processing yourself, here's how to do that: ```python >>> from transformers import AutoImageProcessor, AutoModelForDepthEstimation >>> import torch >>> import numpy as np >>> from PIL import Image >>> import requests >>> url = "http://images.cocodataset.org/val2017/000000039769.jp...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/depth_anything_v2.md
https://huggingface.co/docs/transformers/en/model_doc/depth_anything_v2/#using-the-model-yourself
#using-the-model-yourself
.md
363_4
A list of official Hugging Face and community (indicated by 🌎) resources to help you get started with Depth Anything. - [Monocular depth estimation task guide](../tasks/monocular_depth_estimation) - [Depth Anything V2 demo](https://huggingface.co/spaces/depth-anything/Depth-Anything-V2). - A notebook showcasing infe...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/depth_anything_v2.md
https://huggingface.co/docs/transformers/en/model_doc/depth_anything_v2/#resources
#resources
.md
363_5
This is the configuration class to store the configuration of a [`DepthAnythingModel`]. It is used to instantiate a DepthAnything model according to the specified arguments, defining the model architecture. Instantiating a configuration with the defaults will yield a similar configuration to that of the DepthAnything [...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/depth_anything_v2.md
https://huggingface.co/docs/transformers/en/model_doc/depth_anything_v2/#depthanythingconfig
#depthanythingconfig
.md
363_6
Depth Anything Model with a depth estimation head on top (consisting of 3 convolutional layers) e.g. for KITTI, NYUv2. This model is a PyTorch [torch.nn.Module](https://pytorch.org/docs/stable/nn.html#torch.nn.Module) subclass. Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter r...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/depth_anything_v2.md
https://huggingface.co/docs/transformers/en/model_doc/depth_anything_v2/#depthanythingfordepthestimation
#depthanythingfordepthestimation
.md
363_7
<!--Copyright 2020 The HuggingFace Team. All rights reserved. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agr...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/
.md
364_0
<div class="flex flex-wrap space-x-1"> <a href="https://huggingface.co/models?filter=albert"> <img alt="Models" src="https://img.shields.io/badge/All_model_pages-albert-blueviolet"> </a> <a href="https://huggingface.co/spaces/docs-demos/albert-base-v2"> <img alt="Spaces" src="https://img.shields.io/badge/%F0%9F%A4%97%2...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#albert
#albert
.md
364_1
The ALBERT model was proposed in [ALBERT: A Lite BERT for Self-supervised Learning of Language Representations](https://arxiv.org/abs/1909.11942) by Zhenzhong Lan, Mingda Chen, Sebastian Goodman, Kevin Gimpel, Piyush Sharma, Radu Soricut. It presents two parameter-reduction techniques to lower memory consumption and in...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#overview
#overview
.md
364_2
- ALBERT is a model with absolute position embeddings so it's usually advised to pad the inputs on the right rather than the left. - ALBERT uses repeating layers which results in a small memory footprint, however the computational cost remains similar to a BERT-like architecture with the same number of hidden layers as...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#usage-tips
#usage-tips
.md
364_3
PyTorch includes a native scaled dot-product attention (SDPA) operator as part of `torch.nn.functional`. This function encompasses several implementations that can be applied depending on the inputs and the hardware in use. See the [official documentation](https://pytorch.org/docs/stable/generated/torch.nn.functional.s...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#using-scaled-dot-product-attention-sdpa
#using-scaled-dot-product-attention-sdpa
.md
364_4
|batch_size|seq_len|Time per batch (eager - s)| Time per batch (sdpa - s)| Speedup (%)| Eager peak mem (MB)| sdpa peak mem (MB)| Mem saving (%)| |----------|-------|--------------------------|--------------------------|------------|--------------------|-------------------|---------------| |2 |256 |0.028 ...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#training-for-100-iterations
#training-for-100-iterations
.md
364_5
|batch_size|seq_len|Per token latency eager (ms)|Per token latency SDPA (ms)|Speedup (%) |Mem eager (MB)|Mem BT (MB)|Mem saved (%)| |----------|-------|----------------------------|---------------------------|------------|--------------|-----------|-------------| |4 |128 |0.083 |0.071 ...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#inference-with-50-batches
#inference-with-50-batches
.md
364_6
The resources provided in the following sections consist of a list of official Hugging Face and community (indicated by 🌎) resources to help you get started with AlBERT. If you're interested in submitting a resource to be included here, please feel free to open a Pull Request and we'll review it! The resource should i...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#resources
#resources
.md
364_7
This is the configuration class to store the configuration of a [`AlbertModel`] or a [`TFAlbertModel`]. It is used to instantiate an ALBERT model according to the specified arguments, defining the model architecture. Instantiating a configuration with the defaults will yield a similar configuration to that of the ALBER...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#albertconfig
#albertconfig
.md
364_8
Construct an ALBERT tokenizer. Based on [SentencePiece](https://github.com/google/sentencepiece). This tokenizer inherits from [`PreTrainedTokenizer`] which contains most of the main methods. Users should refer to this superclass for more information regarding those methods. Args: vocab_file (`str`): [SentencePiece...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#alberttokenizer
#alberttokenizer
.md
364_9
Construct a "fast" ALBERT tokenizer (backed by HuggingFace's *tokenizers* library). Based on [Unigram](https://huggingface.co/docs/tokenizers/python/latest/components.html?highlight=unigram#models). This tokenizer inherits from [`PreTrainedTokenizerFast`] which contains most of the main methods. Users should refer to t...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#alberttokenizerfast
#alberttokenizerfast
.md
364_10
models.albert.modeling_albert.AlbertForPreTrainingOutput Output type of [`AlbertForPreTraining`]. Args: loss (*optional*, returned when `labels` is provided, `torch.FloatTensor` of shape `(1,)`): Total loss as the sum of the masked language modeling loss and the next sequence prediction (classification) loss. predi...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#albert-specific-outputs
#albert-specific-outputs
.md
364_11
The bare ALBERT Model transformer outputting raw hidden-states without any specific head on top. This model inherits from [`PreTrainedModel`]. Check the superclass documentation for the generic methods the library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning head...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#albertmodel
#albertmodel
.md
364_12
Albert Model with two heads on top as done during the pretraining: a `masked language modeling` head and a `sentence order prediction (classification)` head. This model inherits from [`PreTrainedModel`]. Check the superclass documentation for the generic methods the library implements for all its model (such as downl...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#albertforpretraining
#albertforpretraining
.md
364_13
Albert Model with a `language modeling` head on top. This model inherits from [`PreTrainedModel`]. Check the superclass documentation for the generic methods the library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads etc.) This model is also a PyTorch [torc...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#albertformaskedlm
#albertformaskedlm
.md
364_14
Albert Model transformer with a sequence classification/regression head on top (a linear layer on top of the pooled output) e.g. for GLUE tasks. This model inherits from [`PreTrainedModel`]. Check the superclass documentation for the generic methods the library implements for all its model (such as downloading or sav...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#albertforsequenceclassification
#albertforsequenceclassification
.md
364_15
Albert Model with a multiple choice classification head on top (a linear layer on top of the pooled output and a softmax) e.g. for RocStories/SWAG tasks. This model inherits from [`PreTrainedModel`]. Check the superclass documentation for the generic methods the library implements for all its model (such as downloadi...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#albertformultiplechoice
#albertformultiplechoice
.md
364_16
Albert Model with a token classification head on top (a linear layer on top of the hidden-states output) e.g. for Named-Entity-Recognition (NER) tasks. This model inherits from [`PreTrainedModel`]. Check the superclass documentation for the generic methods the library implements for all its model (such as downloading...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#albertfortokenclassification
#albertfortokenclassification
.md
364_17
Albert Model with a span classification head on top for extractive question-answering tasks like SQuAD (a linear layers on top of the hidden-states output to compute `span start logits` and `span end logits`). This model inherits from [`PreTrainedModel`]. Check the superclass documentation for the generic methods the...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#albertforquestionanswering
#albertforquestionanswering
.md
364_18
No docstring available for TFAlbertModel Methods: call
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#tfalbertmodel
#tfalbertmodel
.md
364_19
No docstring available for TFAlbertForPreTraining Methods: call
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#tfalbertforpretraining
#tfalbertforpretraining
.md
364_20
No docstring available for TFAlbertForMaskedLM Methods: call
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#tfalbertformaskedlm
#tfalbertformaskedlm
.md
364_21
No docstring available for TFAlbertForSequenceClassification Methods: call
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#tfalbertforsequenceclassification
#tfalbertforsequenceclassification
.md
364_22
No docstring available for TFAlbertForMultipleChoice Methods: call
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#tfalbertformultiplechoice
#tfalbertformultiplechoice
.md
364_23
No docstring available for TFAlbertForTokenClassification Methods: call
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#tfalbertfortokenclassification
#tfalbertfortokenclassification
.md
364_24
No docstring available for TFAlbertForQuestionAnswering Methods: call </tf> <jax>
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#tfalbertforquestionanswering
#tfalbertforquestionanswering
.md
364_25
No docstring available for FlaxAlbertModel Methods: __call__
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#flaxalbertmodel
#flaxalbertmodel
.md
364_26
No docstring available for FlaxAlbertForPreTraining Methods: __call__
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#flaxalbertforpretraining
#flaxalbertforpretraining
.md
364_27
No docstring available for FlaxAlbertForMaskedLM Methods: __call__
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#flaxalbertformaskedlm
#flaxalbertformaskedlm
.md
364_28
No docstring available for FlaxAlbertForSequenceClassification Methods: __call__
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#flaxalbertforsequenceclassification
#flaxalbertforsequenceclassification
.md
364_29
No docstring available for FlaxAlbertForMultipleChoice Methods: __call__
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#flaxalbertformultiplechoice
#flaxalbertformultiplechoice
.md
364_30
No docstring available for FlaxAlbertForTokenClassification Methods: __call__
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#flaxalbertfortokenclassification
#flaxalbertfortokenclassification
.md
364_31
No docstring available for FlaxAlbertForQuestionAnswering Methods: __call__ </jax> </frameworkcontent>
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/albert.md
https://huggingface.co/docs/transformers/en/model_doc/albert/#flaxalbertforquestionanswering
#flaxalbertforquestionanswering
.md
364_32
<!--Copyright 2024 The HuggingFace Team. All rights reserved. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agreed to...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/dinov2_with_registers.md
https://huggingface.co/docs/transformers/en/model_doc/dinov2_with_registers/
.md
365_0
The DINOv2 with Registers model was proposed in [Vision Transformers Need Registers](https://arxiv.org/abs/2309.16588) by Timothée Darcet, Maxime Oquab, Julien Mairal, Piotr Bojanowski. The [Vision Transformer](vit) (ViT) is a transformer encoder model (BERT-like) originally introduced to do supervised image classifi...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/dinov2_with_registers.md
https://huggingface.co/docs/transformers/en/model_doc/dinov2_with_registers/#overview
#overview
.md
365_1
This is the configuration class to store the configuration of a [`Dinov2WithRegistersModel`]. It is used to instantiate an Dinov2WithRegisters model according to the specified arguments, defining the model architecture. Instantiating a configuration with the defaults will yield a similar configuration to that of the DI...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/dinov2_with_registers.md
https://huggingface.co/docs/transformers/en/model_doc/dinov2_with_registers/#dinov2withregistersconfig
#dinov2withregistersconfig
.md
365_2
The bare Dinov2WithRegisters Model transformer outputting raw hidden-states without any specific head on top. This model is a PyTorch [torch.nn.Module](https://pytorch.org/docs/stable/nn.html#torch.nn.Module) subclass. Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to g...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/dinov2_with_registers.md
https://huggingface.co/docs/transformers/en/model_doc/dinov2_with_registers/#dinov2withregistersmodel
#dinov2withregistersmodel
.md
365_3
Dinov2WithRegisters Model transformer with an image classification head on top (a linear layer on top of the final hidden state of the [CLS] token) e.g. for ImageNet. This model is a PyTorch [torch.nn.Module](https://pytorch.org/docs/stable/nn.html#torch.nn.Module) subclass. Use it as a regular PyTorch Module and ref...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/dinov2_with_registers.md
https://huggingface.co/docs/transformers/en/model_doc/dinov2_with_registers/#dinov2withregistersforimageclassification
#dinov2withregistersforimageclassification
.md
365_4
<!--Copyright 2023 The HuggingFace Team. All rights reserved. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agr...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/vitdet.md
https://huggingface.co/docs/transformers/en/model_doc/vitdet/
.md
366_0
The ViTDet model was proposed in [Exploring Plain Vision Transformer Backbones for Object Detection](https://arxiv.org/abs/2203.16527) by Yanghao Li, Hanzi Mao, Ross Girshick, Kaiming He. VitDet leverages the plain [Vision Transformer](vit) for the task of object detection. The abstract from the paper is the followin...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/vitdet.md
https://huggingface.co/docs/transformers/en/model_doc/vitdet/#overview
#overview
.md
366_1
This is the configuration class to store the configuration of a [`VitDetModel`]. It is used to instantiate an VitDet model according to the specified arguments, defining the model architecture. Instantiating a configuration with the defaults will yield a similar configuration to that of the VitDet [google/vitdet-base-p...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/vitdet.md
https://huggingface.co/docs/transformers/en/model_doc/vitdet/#vitdetconfig
#vitdetconfig
.md
366_2
The bare VitDet Transformer model outputting raw hidden-states without any specific head on top. This model is a PyTorch [torch.nn.Module](https://pytorch.org/docs/stable/nn.html#torch.nn.Module) subclass. Use it as a regular PyTorch Module and refer to the PyTorch documentation for all matter related to general usage ...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/vitdet.md
https://huggingface.co/docs/transformers/en/model_doc/vitdet/#vitdetmodel
#vitdetmodel
.md
366_3
<!--Copyright 2021 The HuggingFace Team. All rights reserved. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agr...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/speech_to_text.md
https://huggingface.co/docs/transformers/en/model_doc/speech_to_text/
.md
367_0
The Speech2Text model was proposed in [fairseq S2T: Fast Speech-to-Text Modeling with fairseq](https://arxiv.org/abs/2010.05171) by Changhan Wang, Yun Tang, Xutai Ma, Anne Wu, Dmytro Okhonko, Juan Pino. It's a transformer-based seq2seq (encoder-decoder) model designed for end-to-end Automatic Speech Recognition (ASR) a...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/speech_to_text.md
https://huggingface.co/docs/transformers/en/model_doc/speech_to_text/#overview
#overview
.md
367_1
Speech2Text is a speech model that accepts a float tensor of log-mel filter-bank features extracted from the speech signal. It's a transformer-based seq2seq model, so the transcripts/translations are generated autoregressively. The `generate()` method can be used for inference. The [`Speech2TextFeatureExtractor`] cla...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/speech_to_text.md
https://huggingface.co/docs/transformers/en/model_doc/speech_to_text/#inference
#inference
.md
367_2
This is the configuration class to store the configuration of a [`Speech2TextModel`]. It is used to instantiate a Speech2Text model according to the specified arguments, defining the model architecture. Instantiating a configuration with the defaults will yield a similar configuration to that of the Speech2Text [facebo...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/speech_to_text.md
https://huggingface.co/docs/transformers/en/model_doc/speech_to_text/#speech2textconfig
#speech2textconfig
.md
367_3
Construct an Speech2Text tokenizer. This tokenizer inherits from [`PreTrainedTokenizer`] which contains some of the main methods. Users should refer to the superclass for more information regarding such methods. Args: vocab_file (`str`): File containing the vocabulary. spm_file (`str`): Path to the [SentencePiece](...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/speech_to_text.md
https://huggingface.co/docs/transformers/en/model_doc/speech_to_text/#speech2texttokenizer
#speech2texttokenizer
.md
367_4
Constructs a Speech2Text feature extractor. This feature extractor inherits from [`Speech2TextFeatureExtractor`] which contains most of the main methods. Users should refer to this superclass for more information regarding those methods. This class extracts mel-filter bank features from raw speech using TorchAudio ...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/speech_to_text.md
https://huggingface.co/docs/transformers/en/model_doc/speech_to_text/#speech2textfeatureextractor
#speech2textfeatureextractor
.md
367_5
Constructs a Speech2Text processor which wraps a Speech2Text feature extractor and a Speech2Text tokenizer into a single processor. [`Speech2TextProcessor`] offers all the functionalities of [`Speech2TextFeatureExtractor`] and [`Speech2TextTokenizer`]. See the [`~Speech2TextProcessor.__call__`] and [`~Speech2TextProc...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/speech_to_text.md
https://huggingface.co/docs/transformers/en/model_doc/speech_to_text/#speech2textprocessor
#speech2textprocessor
.md
367_6
The bare Speech2Text Model outputting raw hidden-states without any specific head on top. This model inherits from [`PreTrainedModel`]. Check the superclass documentation for the generic methods the library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads etc.) ...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/speech_to_text.md
https://huggingface.co/docs/transformers/en/model_doc/speech_to_text/#speech2textmodel
#speech2textmodel
.md
367_7
The Speech2Text Model with a language modeling head. Can be used for summarization. This model inherits from [`PreTrainedModel`]. Check the superclass documentation for the generic methods the library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads etc.) This ...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/speech_to_text.md
https://huggingface.co/docs/transformers/en/model_doc/speech_to_text/#speech2textforconditionalgeneration
#speech2textforconditionalgeneration
.md
367_8
No docstring available for TFSpeech2TextModel Methods: call
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/speech_to_text.md
https://huggingface.co/docs/transformers/en/model_doc/speech_to_text/#tfspeech2textmodel
#tfspeech2textmodel
.md
367_9
No docstring available for TFSpeech2TextForConditionalGeneration Methods: call </tf> </frameworkcontent>
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/speech_to_text.md
https://huggingface.co/docs/transformers/en/model_doc/speech_to_text/#tfspeech2textforconditionalgeneration
#tfspeech2textforconditionalgeneration
.md
367_10
<!--Copyright 2024 Kyutai and The HuggingFace Team. All rights reserved. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/helium.md
https://huggingface.co/docs/transformers/en/model_doc/helium/
.md
368_0
Helium was proposed in [Announcing Helium-1 Preview](https://kyutai.org/2025/01/13/helium.html) by the Kyutai Team. Helium-1 preview is a lightweight language model with 2B parameters, targeting edge and mobile devices. It supports the following languages: English, French, German, Italian, Portuguese, Spanish. - **...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/helium.md
https://huggingface.co/docs/transformers/en/model_doc/helium/#overview
#overview
.md
368_1
<!-- This section describes the evaluation protocols and provides the results. -->
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/helium.md
https://huggingface.co/docs/transformers/en/model_doc/helium/#evaluation
#evaluation
.md
368_2
<!-- This should link to a Dataset Card if possible. --> The model was evaluated on MMLU, TriviaQA, NaturalQuestions, ARC Easy & Challenge, Open Book QA, Common Sense QA, Physical Interaction QA, Social Interaction QA, HellaSwag, WinoGrande, Multilingual Knowledge QA, FLORES 200.
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/helium.md
https://huggingface.co/docs/transformers/en/model_doc/helium/#testing-data
#testing-data
.md
368_3
<!-- These are the evaluation metrics being used, ideally with a description of why. --> We report accuracy on MMLU, ARC, OBQA, CSQA, PIQA, SIQA, HellaSwag, WinoGrande. We report exact match on TriviaQA, NQ and MKQA. We report BLEU on FLORES.
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/helium.md
https://huggingface.co/docs/transformers/en/model_doc/helium/#metrics
#metrics
.md
368_4
| Benchmark | Helium-1 Preview | HF SmolLM2 (1.7B) | Gemma-2 (2.6B) | Llama-3.2 (3B) | Qwen2.5 (1.5B) | |--------------|--------|--------|--------|--------|--------| | | | | | | | | MMLU | 51.2 | 50.4 | 53.1 | 56.6 | 61.0 | | NQ | 17.3 | 15.1 | 17.7 | 22.0 | 13.1 | | TQA | 47.9 | 45.4 | 49.9 | 53.6 | 35.9 | | ARC E ...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/helium.md
https://huggingface.co/docs/transformers/en/model_doc/helium/#english-results
#english-results
.md
368_5
| Language | Benchmark | Helium-1 Preview | HF SmolLM2 (1.7B) | Gemma-2 (2.6B) | Llama-3.2 (3B) | Qwen2.5 (1.5B) | |-----|--------------|--------|--------|--------|--------|--------| | | | | | | | | |German| MMLU | 45.6 | 35.3 | 45.0 | 47.5 | 49.5 | || ARC C | 56.7 | 38.4 | 54.7 | 58.3 | 60.2 | || HS | 53.5 | 33.9 | 53...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/helium.md
https://huggingface.co/docs/transformers/en/model_doc/helium/#multilingual-results
#multilingual-results
.md
368_6
| Hyperparameter | Value | |--------------|--------| | Layers | 24 | | Heads | 20 | | Model dimension | 2560 | | MLP dimension | 7040 | | Context size | 4096 | | Theta RoPE | 100,000 | Tips: - This model was contributed by [Laurent Mazare](https://huggingface.co/lmz)
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/helium.md
https://huggingface.co/docs/transformers/en/model_doc/helium/#model-architecture-and-objective
#model-architecture-and-objective
.md
368_7
`Helium` can be found on the [Huggingface Hub](https://huggingface.co/collections/kyutai/helium-1-preview) In the following, we demonstrate how to use `helium-1-preview` for the inference. ```python >>> from transformers import AutoModelForCausalLM, AutoTokenizer >>> device = "cuda" # the device to load the model o...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/helium.md
https://huggingface.co/docs/transformers/en/model_doc/helium/#usage-tips
#usage-tips
.md
368_8
HeliumConfig This is the configuration class to store the configuration of a [`HeliumModel`]. It is used to instantiate an Helium model according to the specified arguments, defining the model architecture. Instantiating a configuration with the defaults will yield a similar configuration to that of the Helium 2b mod...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/helium.md
https://huggingface.co/docs/transformers/en/model_doc/helium/#heliumconfig
#heliumconfig
.md
368_9
HeliumModel The bare Helium Model outputting raw hidden-states without any specific head on top. This model inherits from [`PreTrainedModel`]. Check the superclass documentation for the generic methods the library implements for all its model (such as downloading or saving, resizing the input embeddings, pruning heads ...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/helium.md
https://huggingface.co/docs/transformers/en/model_doc/helium/#heliummodel
#heliummodel
.md
368_10
HeliumForCausalLM - forward
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/helium.md
https://huggingface.co/docs/transformers/en/model_doc/helium/#heliumforcausallm
#heliumforcausallm
.md
368_11
HeliumForSequenceClassification The Helium Model transformer with a sequence classification head on top (linear layer). [`HeliumForSequenceClassification`] uses the last token in order to do the classification, as other causal models (e.g. GPT-2) do. Since it does classification on the last token, it requires to ...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/helium.md
https://huggingface.co/docs/transformers/en/model_doc/helium/#heliumforsequenceclassification
#heliumforsequenceclassification
.md
368_12
HeliumForTokenClassification The Helium Model transformer with a token classification head on top (a linear layer on top of the hidden-states output) e.g. for Named-Entity-Recognition (NER) tasks. This model inherits from [`PreTrainedModel`]. Check the superclass documentation for the generic methods the library im...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/helium.md
https://huggingface.co/docs/transformers/en/model_doc/helium/#heliumfortokenclassification
#heliumfortokenclassification
.md
368_13
<!--Copyright 2023 The HuggingFace Team. All rights reserved. Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. You may obtain a copy of the License at http://www.apache.org/licenses/LICENSE-2.0 Unless required by applicable law or agr...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/autoformer.md
https://huggingface.co/docs/transformers/en/model_doc/autoformer/
.md
369_0
The Autoformer model was proposed in [Autoformer: Decomposition Transformers with Auto-Correlation for Long-Term Series Forecasting](https://arxiv.org/abs/2106.13008) by Haixu Wu, Jiehui Xu, Jianmin Wang, Mingsheng Long. This model augments the Transformer as a deep decomposition architecture, which can progressively...
/Users/nielsrogge/Documents/python_projecten/transformers/docs/source/en/model_doc/autoformer.md
https://huggingface.co/docs/transformers/en/model_doc/autoformer/#overview
#overview
.md
369_1