EADST

gemma-3n-E4B-it配置文件config.json解析

{
  "architectures": ["Gemma3nForConditionalGeneration"]  // 模型主架构名称
  "audio_config": {  // 音频模型配置开始
    "conf_attention_chunk_size": 12,  // 注意力块大小
    "conf_attention_context_left": 13,  // 注意力左上下文窗口
    "conf_attention_context_right": 0,  // 注意力右上下文窗口
    "conf_attention_logit_cap": 50.0,  // logits 截断上限
    "conf_conv_kernel_size": 5,  // 卷积核大小
    "conf_num_attention_heads": 8,  // 注意力头数量
    "conf_num_hidden_layers": 12,  // transformer 层数
    "conf_positional_bias_size": 256,  // 位置偏置大小
    "conf_reduction_factor": 4,  // 降采样因子
    "conf_residual_weight": 0.5,  // 残差连接权重
    "gradient_clipping": 10000000000.0,  // 梯度裁剪值
    "hidden_size": 1536,  // 隐藏层维度
    "input_feat_size": 128,  // 输入特征维度
    "model_type": "gemma3n_audio",  // 音频模型类型
    "rms_norm_eps": 1e-06,  // RMSNorm 的 epsilon
    "sscp_conv_channel_size": [128, 32],  // 卷积层通道数量
    "sscp_conv_eps": 0.001,  // 卷积层 epsilon
    "sscp_conv_kernel_size": [[3, 3], [3, 3]],  // 每层卷积核大小
    "sscp_conv_stride_size": [[2, 2], [2, 2]],  // 每层卷积步幅
    "torch_dtype": "bfloat16",  // 数据类型为 bfloat16
    "vocab_offset": 262272,  // 词表偏移
    "vocab_size": 128  // 音频词表大小
  },
  "audio_soft_tokens_per_image": 188,  // 每段音频的软 token 数
  "audio_token_id": 262273,  // 音频 token 的 ID
  "boa_token_id": 256000,  // 音频开始 token ID
  "boi_token_id": 255999,  // 图像开始 token ID
  "eoa_token_id": 262272,  // 音频结束 token ID
  "eoi_token_id": 262144,  // 图像结束 token ID
  "eos_token_id": [1, 106],  // 文本结束 token ID
  "image_token_id": 262145,  // 图像 token ID
  "initializer_range": 0.02,  // 参数初始化范围
  "model_type": "gemma3n",  // 总体模型类型
  "text_config": {  // 文本模型配置开始
    "activation_sparsity_pattern": [...],  // 激活稀疏性配置
    "altup_active_idx": 0,  // ALTUP 激活索引
    "altup_coef_clip": 120.0,  // ALTUP 系数裁剪
    "altup_correct_scale": true,  // 是否修正缩放
    "altup_lr_multiplier": 1.0,  // ALTUP 学习率因子
    "altup_num_inputs": 4,  // ALTUP 输入数
    "attention_bias": false,  // 是否使用注意力 bias
    "attention_dropout": 0.0,  // 注意力 dropout
    "final_logit_softcapping": 30.0,  // logits 最终上限
    "head_dim": 256,  // 每个注意力头的维度
    "hidden_activation": "gelu_pytorch_tanh",  // 激活函数类型
    "hidden_size": 2048,  // 隐藏层维度
    "hidden_size_per_layer_input": 256,  // 每层输入维度
    "initializer_range": 0.02,  // 初始化范围
    "intermediate_size": 16384,  // FeedForward 中间层大小
    "laurel_rank": 64,  // Laurel 模块秩值
    "layer_types": [...],  // 每层使用的注意力类型
    "max_position_embeddings": 32768,  // 最大位置编码长度
    "model_type": "gemma3n_text",  // 文本模型类型
    "num_attention_heads": 8,  // 注意力头数
    "num_hidden_layers": 35,  // 文本模型层数
    "num_key_value_heads": 2,  // KV 头数量
    "num_kv_shared_layers": 15,  // 共享 KV 的层数
    "query_pre_attn_scalar": 256,  // 注意力前缩放因子
    "rms_norm_eps": 1e-06,  // RMSNorm 的 epsilon
    "rope_local_base_freq": 10000.0,  // RoPE 的局部基频
    "rope_scaling": null,  // RoPE 缩放参数
    "rope_theta": 1000000.0,  // RoPE 的 theta 参数
    "sliding_window": 512,  // 滑动窗口大小
    "torch_dtype": "bfloat16",  // 数据类型为 bfloat16
    "use_cache": true,  // 启用缓存
    "vocab_size": 262400,  // 总词表大小
    "vocab_size_per_layer_input": 262144  // 每层词表输入大小
  },
  "vision_config": {  // 图像模型配置开始
    "architecture": "mobilenetv5_300m_enc",  // 使用的视觉骨干网络
    "do_pooling": true,  // 是否进行池化
    "hidden_size": 2048,  // 隐藏层大小
    "initializer_range": 0.02,  // 初始化范围
    "label_names": ["LABEL_0", "LABEL_1"],  // 类别标签名
    "model_type": "gemma3n_vision",  // 视觉模型类型
    "num_classes": 2,  // 分类数
    "rms_norm_eps": 1e-06,  // RMSNorm 的 epsilon
    "torch_dtype": "bfloat16",  // 数据类型为 bfloat16
    "vocab_offset": 262144,  // 图像 token 偏移
    "vocab_size": 128  // 图像词表大小
  },
  "vision_soft_tokens_per_image": 256  // 每张图的软 token 数
}
相关标签
About Me
XD
Goals determine what you are going to be.
Category
标签云
Cloudreve 证件照 Miniforge diffusers Land MD5 PIP PDF printf 净利润 Gemma Shortcut Excel CAM ModelScope v0.dev Diagram PyTorch Animate UNIX Windows Hungarian GPTQ git-lfs Password logger Conda Interview 算法题 VPN GGML Card Tracking scipy SVR Claude CUDA NameSilo GPT4 C++ Statistics CC Pickle Disk 音频 SAM XML Use JSON Template Streamlit SQLite 签证 Logo Food Ptyhon BTC Github OpenCV YOLO Safetensors WebCrawler Heatmap Data Quantization Breakpoint Augmentation Pillow VGG-16 LLM API Vim TSV Anaconda Michelin COCO mmap Image2Text Zip Video uwsgi git TTS Hilton FP8 Markdown FP64 llama.cpp Knowledge Qwen2.5 Domain GoogLeNet Bin FP32 Color Tiktoken 域名 腾讯云 Distillation v2ray CV NLP LaTeX Base64 RAR DeepSeek Git Algorithm LoRA ONNX HaggingFace HuggingFace Docker Dataset Mixtral ChatGPT CTC Python OpenAI tar Linux Freesound UI Django hf Google Quantize Datetime QWEN LeetCode Math SPIE FlashAttention transformers 飞书 Web Jupyter 搞笑 Hotel 版权 CEIR Paper Qwen2 LLAMA tqdm Random DeepStream Pytorch Jetson Magnet Input Tensor Sklearn 公式 Bert 阿里云 Transformers FastAPI PyCharm 多进程 BF16 EXCEL VSCode RGB Bipartite Plate Website Attention IndexTTS2 Bitcoin Pandas InvalidArgumentError Llama uWSGI 报税 Crawler Paddle Ubuntu 多线程 Clash CLAP Translation GIT Numpy XGBoost Firewall 关于博主 Proxy PDB Permission Nginx NLTK BeautifulSoup Plotly TensorRT WAN FP16 AI Vmess Review ResNet-50 SQL CSV Baidu torchinfo OCR 继承 TensorFlow Qwen 财报
站点统计

本站现有博文309篇,共被浏览735801

本站已经建立2373天!

热门文章
文章归档
回到顶部