上一页 1 ··· 507 508 509 510 511 512 513 514 515 ··· 865 下一页
摘要: Transformers 源码解析(九十七) .\models\roberta_prelayernorm\__init__.py # 引入类型检查依赖,用于在类型检查环境下做条件导入 from typing import TYPE_CHECKING # 从工具模块中导入相关工具和异常 from .. 阅读全文
posted @ 2024-06-29 16:57 绝不原创的飞龙 阅读(92) 评论(0) 推荐(0)
摘要: Transformers 源码解析(九十六) .\models\roberta\tokenization_roberta_fast.py # coding=utf-8 # Copyright 2018 The Open AI Team Authors and The HuggingFace Inc. 阅读全文
posted @ 2024-06-29 16:57 绝不原创的飞龙 阅读(144) 评论(0) 推荐(0)
摘要: Transformers 源码解析(九十九) .\models\sam\image_processing_sam.py # 指定编码格式为 UTF-8 # 版权声明和许可信息 # 根据 Apache 许可证 2.0 版本,除非符合许可证规定,否则不得使用此文件 # 获取许可证的详细信息,请访问指定的 阅读全文
posted @ 2024-06-29 16:56 绝不原创的飞龙 阅读(108) 评论(0) 推荐(0)
摘要: Transformers 源码解析(九十二) .\models\rag\tokenization_rag.py # coding=utf-8 # 声明文件编码格式为 UTF-8 # 版权声明和许可证信息 # 导入必要的模块和类 import os import warnings from typin 阅读全文
posted @ 2024-06-29 16:56 绝不原创的飞龙 阅读(113) 评论(0) 推荐(0)
摘要: Transformers 源码解析(九十八) .\models\roformer\modeling_tf_roformer.py # 导入所需模块和库 import math from typing import Dict, Optional, Tuple, Union import numpy a 阅读全文
posted @ 2024-06-29 16:56 绝不原创的飞龙 阅读(149) 评论(0) 推荐(0)
摘要: Transformers 源码解析(九十) .\models\pop2piano\tokenization_pop2piano.py # coding=utf-8 # Copyright 2023 The Pop2Piano Authors and The HuggingFace Inc. team 阅读全文
posted @ 2024-06-29 16:56 绝不原创的飞龙 阅读(89) 评论(0) 推荐(0)
摘要: Transformers 源码解析(九) .\models\albert\configuration_albert.py # 引入 OrderedDict 用于有序字典,Mapping 用于类型提示 from collections import OrderedDict from typing im 阅读全文
posted @ 2024-06-29 16:56 绝不原创的飞龙 阅读(189) 评论(0) 推荐(0)
摘要: Transformers 源码解析(二十一) .\models\blip\modeling_tf_blip_text.py # 导入所需的库和模块 from __future__ import annotations import math # 导入数学库,用于数学运算 from typing im 阅读全文
posted @ 2024-06-29 16:55 绝不原创的飞龙 阅读(278) 评论(0) 推荐(0)
摘要: Transformers 源码解析(二十五) .\models\clap\processing_clap.py """ Audio/Text processor class for CLAP """ from ...processing_utils import ProcessorMixin # 导 阅读全文
posted @ 2024-06-29 16:55 绝不原创的飞龙 阅读(306) 评论(0) 推荐(0)
摘要: Transformers 源码解析(二十四) .\models\canine\tokenization_canine.py # coding=utf-8 # Copyright Google AI and The HuggingFace Inc. team. All rights reserved. 阅读全文
posted @ 2024-06-29 15:50 绝不原创的飞龙 阅读(184) 评论(0) 推荐(0)
上一页 1 ··· 507 508 509 510 511 512 513 514 515 ··· 865 下一页