深度學習
預覽Hugging Face 的語言、視覺、語音和影像模型,微調,以及 Keras 網路
18 個類別,共 111 個節點
- 所屬發行版
- 元編程(專業版)
- 支援等級
- 第 3 級(擬定)
- 所屬包
- 機器學習
機器學習
來自 Hugging Face 模型庫的模型:對話與文字生成、嵌入、摘要與翻譯、影像與語音識別、Stable Diffusion、LoRA 微調、Keras 網路與 ONNX,以及 YOLO 目標檢測。
微調設定
微調設定Settings for a LoRA or QLoRA fine-tune.縮放係數How strongly the adapter applies.批大小Examples per batch.裝置Where it trains.隨機失活The adapter's dropout.輪數Passes over the data.四位量化Whether the base model is held in 4-bit (QLoRA).梯度累積Batches per step.學習率The learning rate.最大長度The longest example, in tokens.最大步數The step limit; 0 for none.秩The adapter's rank.種子The seed.轉為文字One line, as a preview shows it.
生成設定
生成設定Settings for generating text.最大新詞元數The most tokens a reply may have.重複懲罰How much repeating is discouraged.取樣Whether words are sampled rather than always the likeliest.種子The seed sampling starts from.停止於Texts that end the reply.溫度How adventurous sampling is.Top-KHow many of the likeliest words sampling chooses among.Top-PThe share of probability sampling chooses within.轉為文字One line, as a preview shows it.
文字任務
回答問題Answers a question with the passage of a text that answers it.文字分類The labels that best describe a text, best first.零樣本文字分類Scores a text against labels written in words, best first.填充掩碼The likeliest words for the mask token in a text, best first, with the text each makes.載入實體識別器Loads a named-entity recognizer from a Hub repository or a folder.載入掩碼填充模型Loads a masked language model from a Hub repository or a folder.載入問答模型Loads an extractive question-answering model from a Hub repository or a folder.載入文字分類器Loads a text classifier from a Hub repository or a folder.載入零樣本文字分類器Loads a zero-shot text classifier (a model trained on natural-language inference) from a Hub repository or a folder.識別實體The names a text mentions and what each is - PER, LOC, ORG, MISC for most English models - in the order they appear.
Keras 層
相加Adds several branches of the same shape, element by element, as a residual connection does.批歸一化Rescales its inputs to a steady mean and spread, batch by batch, which makes deeper networks train faster.拼接Joins several branches side by side, along their last axis.二維卷積A 2D convolution: small filters slid over a picture-shaped input (height, width, channels), each finding one kind of pattern.全連線層A fully connected layer: every output is a weighted sum of every input, then the activation.隨機失活Drops a share of its inputs at random while training, against overfitting; does nothing when predicting.展平Lays a shaped input out as one row of numbers, as a Dense layer after convolutions needs.輸入Where data enters the network: one example's shape, without the batch.層歸一化Rescales each example's features to a steady mean and spread.二維最大池化Halves a picture-shaped input's width and height (by default), keeping the strongest value of each patch.
語言模型
提問Asks a chat model one question and answers with its reply: a one-message conversation, rendered through the model's chat template.對話Says a message in a conversation and answers with the model's reply, and the conversation with both added, to continue from.繼續對話The model's next reply to a conversation that ends with the user's message.計算詞元數How many tokens a text is to a model, which is what its length limits and Generation Settings count.生成文字Continues a text as the model would write it, without a chat template: the model's continuation alone, not the prompt.載入語言模型Loads a language model and its tokenizer from a Hugging Face Hub repository or a folder, downloading what is missing.載入 ONNX 語言模型Loads a language model to run on the ONNX backend: the repository's own ONNX file when it has one, such as one Export Language Model to ONNX wrote, otherwise a graph built from its checkpoint.流式對話Chat, with the reply handed to a function piece by piece as it is written - whole words, line by line - so it can be shown before it is finished.
視覺語言模型
詢問影像Asks a question about a picture.詢問多張影像Asks a question about several pictures at once, shown in order before the question.影像對話Says a message in a conversation, showing a picture with it, and answers with the model's reply and the conversation with both added, to continue from.描述影像Asks the model to describe a picture: "Describe this image."載入視覺語言模型Loads a vision language model and its processor from a Hugging Face Hub repository or a folder, downloading what is missing.建立影像陣列Up to eight pictures as one array, for Ask About Images; unconnected inputs are left out.流式影像對話Chat About Image, with the reply handed to a function piece by piece as it is written, so it can be shown before it is finished.
影像生成
新增 ControlNetAdds a ControlNet to steer a picture: Generate Image, Transform Image or Inpaint Image follows its conditioning picture.用精修器收尾Finishes an SDXL picture with SDXL's refiner: the base model paints the first part of the steps and hands its unfinished picture over, and the refiner paints the rest.生成影像Paints a picture from a description, optionally following ControlNets and finished by SDXL's refiner.局部重繪影像Repaints the part of a picture a mask marks to match a description, and keeps the rest: inpainting, optionally following ControlNets and finished by SDXL's refiner.載入 ControlNetLoads a ControlNet, which makes a picture follow a conditioning picture such as an edge map, a depth map or a pose.載入影像生成器Loads a Stable Diffusion or SDXL pipeline from a Hub repository or a folder in diffusers' layout, with LoRAs when given.變換影像Repaints a picture to match a description, keeping its composition: img2img, optionally following ControlNets and finished by SDXL's refiner.
Keras 模型
構建 Keras 模型Makes a model of the layers between an input and an output.載入 Keras 模型Loads a model saved in Keras's .keras format, by this package or by Python's Keras.預測單個樣本The model's answer for one example.用 Keras 模型預測The model's answers for the rows of a table, as a table with one column per output.儲存 Keras 模型Saves a model in Keras's .keras format: its layers, weights and training setup in one file.訓練 Keras 模型Trains a model on the rows of a table: some columns are what it sees, others what it should answer.
Hugging Face 模型庫
快取資料夾The folder downloaded models are kept in.已下載的模型The model repositories in the cache, with how much disk each takes.下載檔案Downloads one file of a repository into the cache and answers with its path.下載模型Downloads a whole repository, or the files of it that match some patterns, into the cache, and answers with its folder.是否已下載Whether a repository has anything in the cache.
嵌入
餘弦相似度How alike two embeddings are: 1 for the same direction, 0 for unrelated, -1 for opposite.嵌入A text's embedding.嵌入多段文字Several texts' embeddings.載入嵌入模型Loads an embedding model and its tokenizer from a Hub repository or a folder.按相似度排序Orders texts by how close in meaning each is to a query, closest first: semantic search over a short list.
語音模型
載入語音識別器Loads a speech recognizer, its feature extractor and its tokenizer from a Hub repository or a folder.轉寫What is said in a clip, as text.轉寫檔案What is said in a WAV file, as text.帶時間轉寫What is said in a clip, in the segments the recognizer heard, with when each starts and ends.逐詞轉寫What is said in a clip, word by word, with when each word starts and ends: for subtitles that follow the voice, or to find where a word was said.
轉寫設定
深度學習執行時
描述執行時Which libtorch this distribution carries and what it can see, in one line.GPU 是否可用Whether models can run on an NVIDIA GPU here: the machine has one and a driver, and the distribution carries the CUDA build of libtorch.已載入的模型The models this program holds in memory now, one line each.解除安裝所有模型Frees every model this program has loaded.解除安裝模型Frees the memory a model holds.
文字到文字模型
載入文字到文字模型Loads a text-to-text model and its tokenizer from a Hub repository or a folder.摘要A shorter text saying what a longer one says.轉換文字The model's answer to a text as it is, with no task prefix: what instruction-tuned models such as Flan-T5 are asked with.翻譯Translates a text from one language to another, asked as T5 is asked: "translate English to German: ".
視覺模型
影像分類The labels that best describe a picture, best first, from those the classifier knows.零樣本影像分類Scores a picture against labels written in words, best first; the scores add up to 1 across the labels given.載入影像分類器Loads an image classifier and its image processor from a Hub repository or a folder.載入零樣本影像分類器Loads a zero-shot image classifier (an image and a text model trained together) from a Hub repository or a folder.